Questions tagged [field-mapping]

The relationship between from fields and to fields when performing append, merge or similar operations indicating how fields will be populated in the result dataset.

Filter by
Sorted by
Tagged with
0 votes
0 answers
36 views

Preserve string field type and leading zeros when using arcpy.conversion.TableToTable to go from CSV to GDB table? [duplicate]

I'm building an ArcMap script tool that will be run on many different input table schemas for geocoding purposes. When importing from CSV to GDB table using the arcpy.conversion.TableToTable function ...
Paul DiGirolamo's user avatar
0 votes
0 answers
25 views

How to obtain a lower-complexity version of OpenStreetMap?

I would like to make a simple fieldwork map that displays sampling locations with respect to some specific highlighted areas (using polygons). I would like to do this on a relatively simple map that ...
Arjan's user avatar
  • 1
0 votes
4 answers
149 views

Adding Field Map to Append using ArcPy

I have a folder of shapefiles which I want to append to project geodatabase feature classes using ArcPy. So far, as I am testing with just a few shapefiles, the script works fine as long as all the ...
user-0326's user avatar
0 votes
1 answer
128 views

Field mapping with ArcPy

I've joined a point FC (InputPointCopy) with a polyline FC (Polyline) and now I'd like to append the Polyline FC att table to an empty FC of the same geometry. I ran across a custom function at Using ...
liso_maps's user avatar
  • 103
3 votes
1 answer
146 views

Formatting of attribute map for changeAttributeValues method using PyQGIS

I have a PyQGIS script being run from within QGIS that updates attribute values in a GeoPackage, based on a mapping. It currently iterates through fields and features one by one, updating the values ...
Tom Brennan's user avatar
  • 4,407
0 votes
1 answer
134 views

ArcGIS Join Field not adhering to field mapping merge rules in one-to-many join

I am trying to join records from Table B (join table) to Table A (input table) in ArcGIS Pro using the Join Field tool. This is a one-to-many join such that there are multiple records in Table B that ...
David 's user avatar
  • 21
0 votes
1 answer
505 views

Northing and Easting datum coordinates switched in total station; way to correct point locations?

When starting a mapping session on the total station, my team member accidentally switched the X and Y coordinates for the northing and easting for both the station and the backsight datums. We use ...
ArchArchy's user avatar
  • 121
2 votes
1 answer
106 views

Adding geometry to a db table using ArcPy from an existing points dataset

I am attempting to write an ArcPy script to add the geometries of a points data set to records in a db table. Each record in the db table has a field containing a date, and an associated numeric value ...
TreeGIS's user avatar
  • 126
1 vote
1 answer
591 views

Stop Model Builder from resetting field maps when changing input

ArcGIS Pro 3.0.2 I am doing a Spatial Join in Model Builder and set the input as a parameter. I then use the Field Map settings to change the field names and merge rules. This works fine when I run / ...
sushi's user avatar
  • 317
0 votes
0 answers
112 views

Keeping only unique values when using join merge rule with Spatial Join and ArcPy

As part of a longer process, I have two point layers that I am spatially joining together. One point layer has one point per location. The other point layer has multiple points at the same locations. ...
hosta's user avatar
  • 83
0 votes
0 answers
32 views

Configuring Attribute Tables for multiple layers using ArcMap

Each week I am given new ArcMap files with many Network Analyst Routes. When I view the Attribute Table for the Stops, I am presented with 26 fields in a default order when I need to view Six of ...
JohnG's user avatar
  • 1
0 votes
1 answer
781 views

Contingent values in ArcGIS Online - Need to update domain value in field based on another field value

I am trying to build a very simple calculation (or so I believe it should be) in Field Maps. I want the field, we'll call it "Calculations", to populate either "Compliant" or "...
user148449's user avatar
0 votes
1 answer
370 views

Create a function that will return geodataframe

I have created the following function to take Origin = str, Destination = str, line = shapely.geometry.linestring.LineString, node = GeoDataFrame def create_lines_df(Origin, Destination, line_, nodes_)...
Kareem Alaraby's user avatar
0 votes
1 answer
576 views

Implementing FieldMapping parameter in ArcGIS Pro Python Toolbox tool to map fields in two tables

I am trying to create a tool within a Python Toolbox in ArcGIS Pro that will accept a table and a featureclass and allow a user to map the fields from the feature class to fields in the table. ...
W. Kessler's user avatar
0 votes
1 answer
262 views

Service error code 1000

I am trying to use Esri Field Maps to conduct maintenance inspections of stormwater assets. I have multiple layers (i.e. catch basins, outfalls, ditches, etc) each related to a maintenance table ...
Josh B's user avatar
  • 1
3 votes
1 answer
508 views

Copying Object ID from an online layer to offline one using Feature class to Feature class conversion (ArcGIS Pro)

I have an online feature class "A" with a field "OBJECT ID". I am using Feature Class to Feature Class conversion to create a copy in my local Geodatabase. While doing so I ...
soumik chakraborty's user avatar
2 votes
2 answers
212 views

Trying to use fieldmap to append external featureclass/shapefile to new featureclass using external table for mapping

I am trying to work out a way to populate a series of shape files into a new set of Datasets and feature classes. I have an external table of what the destination feature class field name should be ...
Dami Barnes's user avatar
-2 votes
1 answer
155 views

SQL statement (where_clause) does not work for UpdateCursor syntax but same works for SearchCursor syntax

feature class fc1 (daily data) and feature class fc2 (geodatabase) both have unique_id field which will be used to map Col1 rows in fc1 to update corresponding Col2 rows (not all rows) in fc2. Below ...
Kingsley Esezobor's user avatar
0 votes
0 answers
347 views

Issue importing CSV with CSVT (fields format not applied - QGIS 3.18)

I'm trying to import a CSV file with some data and hoping that QGIS will properly format the fields type but so far no luck. I have my data in a file called coords.csv and I made a single line text ...
SpaceTurtle's user avatar
1 vote
1 answer
158 views

What is the field_map_name in findFieldMapIndex ()?

I am using ArcPy with ArcGIS Pro and FieldMappings. FieldMappings are fiddly and I'm struggling to understand a specific function. I need to replace an 'old' fieldMap with a 'new' fieldMap. FieldMaps ...
Maxcot's user avatar
  • 265
0 votes
1 answer
80 views

arcpy.FieldMappings renames input fields internally

I'm trying to make use of Field mappings to merge many datasets into a new one... as per the manual. ... print (type(idealFieldList)) # class 'list' # let's prune the fluff ...
Maxcot's user avatar
  • 265
-3 votes
1 answer
98 views

Reducing number of lines / more efficient coding method for field maps [closed]

I am looking for ways to reduce the number of lines when making field maps in ArcPy (note, I am using ArcPy with ArcMap 10.6). I cannot seem to figure out a way, and am stuck with a significant amount ...
Ayayayayaoh's user avatar
0 votes
1 answer
84 views

ArcMap 'Add Locations' field mappings not showing added field for network analyst layer

I have successfully created a new field 'Status' in the incidents sublayer of a closest-facility network analyst layer, using the 'Add Field to Analysis Layer' tool. However, when I try to populate ...
bbenak's user avatar
  • 11
1 vote
1 answer
109 views

Performing a spatial join to obtain attribute field summaries of nested polygons that are located within polygon regions using ArcPy

I have created an ArcPy script tool that finds depressions from an input DEM, and then generates closed contours (both polyline and polygon outputs) as well as regions (raster and polygon outputs). I ...
AKubes's user avatar
  • 43
2 votes
1 answer
572 views

Adding input field to field map using ArcPy gives RuntimeError

I'm a Python beginner and I would like to export a csv from a feature class, including only some fields. I'm trying to do it using the field mapping control, but I'm doing something wrong because I ...
Carl's user avatar
  • 135
0 votes
1 answer
192 views

ArcPy script doesn't work for TRIM function

I have this code: import arcpy import os def massiveTrim (vrb): y=r"shape path" for i in y: campos = arcpy.ListFields(vrb, "", "String" ) for camp in campos: ...
Hemerson Mora's user avatar
0 votes
0 answers
926 views

QGIS field calculator: Subtracting values from specific fields

I am trying to create an Isopach map of two subsurface formations. If a well has the two formations in question, then I would like a new layer with the data created so I can contour the points. I ...
TySel's user avatar
  • 1
-3 votes
1 answer
1k views

Importing map found on the Internet to QGIS [closed]

I am new to QGIS and I have learned some of the basics. Now, I have found a Soil Map of Germany I want to work with on the internet. My tasks now are as follows. To reduce the size of the map with ...
Simply Hechi's user avatar
-1 votes
1 answer
72 views

ReAsked - Why is manipulating field map schemas inconsistent (ArcGIS)? [duplicate]

I've got a knotty problem which I am trying to solve in a very methodical and deliberate step by step process, to ensure that non-technical colleagues are able to verify the content every step of the ...
Maxcot's user avatar
  • 265
1 vote
1 answer
105 views

Select Issues with Converting Feature Class to Shapefile with only certain fields

This is not a copy of previous questions like Selecting certain fields from feature class to create new feature class in ArcPy? but builds on them. I have two approaches and two different issues. ...
JackOfTales's user avatar
1 vote
1 answer
560 views

Field mapping features to different feature with different field names using ArcPy

I was trying to you this instead of field mapping because field mapping is hard to understand. outfc = r'\\water.com\Blank.gdb\SewerCollection\ssLateralLine' infc = r'\\water.com\Test.gdb\...
Tony's user avatar
  • 53
0 votes
1 answer
577 views

Applying field mapping during Merge using ArcPy

I am trying to merge 10 stream feature classes together using arcpy. But I need to limit the number of fields in the output (all feature classes share the same fields). working_dir = r"C:\Projects\...
gwydion93's user avatar
  • 1,903
1 vote
1 answer
246 views

How to specify fields to use in a merge

I am using arcpy to merge multiple feature classes from a list of feature classes. They all have the same fields. Let's say they all have the fields = ['CO_FIPS', 'MILES', 'FLOOD_ZONE', 'VALID', '...
gwydion93's user avatar
  • 1,903
3 votes
1 answer
420 views

Defining fields to keep and deleting all other fields in feature class using ArcPy?

I am trying to write a script to read a feature class, list all fields and keep only specic ones. I.e. drop all remaining columns. I guess that pseudo code should be: allFields = create list of all ...
maycca's user avatar
  • 3,376
1 vote
0 answers
190 views

Field Mappings control doesn't show the Add Input Field in the context menu of a Python Toolbox

I’m trying to build a Python Toolbox which uses a Field Mappings control (GPFieldMapping parameter). For some reason I don’t manage to get the same behaviour of the Field Mappings control as in the ...
M. Bogdan's user avatar
1 vote
0 answers
132 views

Are feature ids in QGIS and ArcMap stored differently?

I have a shapefile that I use as a layer in ArcMap. Opening the attribute table, shows a fid starting with 0 for the features. If I attach the same shapefile in QGIS and open the attribute table, the ...
haresfur's user avatar
  • 293
3 votes
2 answers
6k views

Using field mapping with ArcPy

I'm having trouble trying to understand how field mapping works in ArcPy. I'm relatively new to Python. In the below example, I want to take a shapefile and append it to a feature class but I want to ...
user137548's user avatar
0 votes
0 answers
126 views

Fieldmapping for mean and max using arcpy

I'm trying to spatial join two features. One polygon layer and one point layer. The point layer contains one field of values that I want the Mean and Min of. Im trying to use the fieldmaper object to ...
birks's user avatar
  • 249
3 votes
1 answer
2k views

Creating Field Mapping parameter in ArcPy Script

I'm trying to create a tool that compares two data sets. I do not want the Feature Compare tool. Most of the field names in the two data sets are the same, but not all. I want a way to map one field ...
Patrick Tighe's user avatar
2 votes
1 answer
421 views

Using ArcPy FieldMappings?

This is a follow up to Output field name not showing up in spatial join result in which I received no response. I am trying to convert a shapefile to a feature class, I also have a GeoJSON file with ...
user32882's user avatar
  • 3,514
0 votes
0 answers
147 views

Calculating field after arcpy.Append_management()?

I have some AutoCAD layers (f.e. Cad1, Cad2) and I want to export them into feature class in a geodatabase (f.e. feature_class). Also I want to calculate field in "feature_class" for objects from CAD. ...
Lora's user avatar
  • 45
0 votes
1 answer
802 views

MultiValue Selection with MultiValue Input

I made this Python Toolbox as a practice run for a larger project I want to do as I am new to python toolboxes. While this was successful I am not able to the result that I want. I want to be able to ...
aguay091's user avatar
1 vote
1 answer
91 views

Merging on specific fields

Lets say I have three shapefiles/features I want to merge: 'florida.shp', 'mississipi.shp' and 'louisiana.shp'. They all have 3 standard fields common to all: 'DFIRMID', 'SFX', and 'FIRMPAN'. I want ...
gwydion93's user avatar
  • 1,903
-1 votes
2 answers
522 views

Field mappings remove field from arcpyTable to Table conversion

I want to export a table but would like to remove one of the fields before doing so using arcpy. I'm trying to use field mappings but am missing something: fields = arcpy.ListFields("some_table") ...
geoJshaun's user avatar
  • 1,525
0 votes
0 answers
202 views

Passing attributes from join features to target features in 'SpatialJoin_analysis'?

I'm doing a spatial join between two polygon data sets (A and B). B polygons are always smaller than A polygons and there's only a small number of them. They have 2 attributes that I'd like to pass on ...
Pitrako Junior's user avatar
1 vote
0 answers
561 views

Renaming ESRI default SHAPE_Length and SHAPE_Area fields [closed]

I have been working on a draft feature class that will eventually go into our production database, and I just tested it against my organization's standards, but it fails because the "SHAPE_Length" and ...
jesnes's user avatar
  • 423
3 votes
1 answer
308 views

Cannot assign output field name to FieldMap

In attempting to map input fields to output fields, I am finding that I cannot correctly assign the output field name. Running the script produces no errors, but for a given FieldMap object, the ...
mwolfe's user avatar
  • 51
2 votes
1 answer
78 views

Merging many different feature classes into one but only taking certain fields from each?

I'm trying to merge ~50 feature classes into 1. The problem is, these feature classes have many different fields, and some that i don't want in the final FC. I can delete the fields one by one ...
Francis MacDonald's user avatar
1 vote
1 answer
135 views

How to bring over only 2 fields from the join feature class when using "SpatialJoin_analysis" and set up a merge rule?

I'm trying to understand how to use FieldMap and FieldMappings. I know very little about objects plus I'm finding the explanations on ESRI website not very good and far from comprehensive. All I'm ...
Pitrako Junior's user avatar
4 votes
1 answer
344 views

What does "Do you want to reset the field mapping" mean in QGIS Refactor Fields dialog?

I want to convert the type of some fields in a vector layer from String to Real. I am trying to use the Processing -> QGIS geoalgorithms -> Vector table tools -> Refactor fields tool to do this. When ...
J. Taylor's user avatar
  • 673