Field calculators (which are available in QGIS, ArcGIS-related products, etc.) can recalculate the values of a single field, on all, or selected records within a table based on a symbolic expression.

learn more… | top users | synonyms

4
votes
3answers
3k views

split string after first word

I want to split a string field after the first word using the space as a delimiter so that "WA ROSSOUW ORANJE BELEGGINGS" becomes "ROSSOUW ORANJE BELEGGINGS". I am using Arcmap10. Thanks.
0
votes
2answers
2k views

Replacing NULL values in geodatabase table?

How do you update NULL values within a geodatabase table using the ArcGIS Field Calculator (service pack 4) without changing other values to NULL? I've tried the suggestions on this previous ...
0
votes
5answers
3k views

Changing null value to specific numbers in ArcGIS for Desktop? [closed]

I have a Excel file showing annual precipitation and I add it on arcmap. When I tried to check it's attribute table the field calculator is passive. I want to change all the Null value to specific ...
1
vote
2answers
305 views

How to populate a text field with double quotes using field calculator

How would I populate a text field with double quotes using the Field Calculator. For example, I want to populate a field as 24". Is there a way to populate fields using the field calculator with ...
0
votes
1answer
42 views

same or similar search word with field calculator

I am using arcgis 10.1 I have two tables A and B need to find attributes of table B data are on the table A I'm doing a join between table A and B now I want to use the field calculator via a script ...
0
votes
1answer
144 views

Error when calculate field using VBscript or Python (slice a field)

I have an expression in VBscript that works well for labeling: Function FindLabel (field) if (INT(RIGHT(field, 2)) <> 1) then FindLabel = INT(MID(field, 8, 3)) &"-"& ...
3
votes
1answer
110 views

Field calculator uses wrong fields when working with joined data

I am having an issue in qgis table joins. i have a joined a csv file to a sqlite database and common id is used for join. the join is displays correctly in attribute table. the attributes in sqlite ...
2
votes
2answers
2k views

Using Value from Iterate Feature Selection to Calculate Field in ArcMap 10.1 ModelBuilder

I have two polygon feature classes, an alignment layer and a parcels layer. I am trying to use ModelBuilder to create a tool that will do the follow: iterate through groups in a single field of a ...
2
votes
1answer
116 views

Replace characters

How to remove a special number of characters of a string, e.g. the last 7 characters? And how to join them as the first characters to the string of another field? Thank you for VBS and Python synthax ...
0
votes
2answers
54 views

trying to add content to the middle of a string

I am trying to add content to the middle of a string by using MyStr = Mid([MyField], 1, 1) and I get an error. I've tried MyStr = Mid([_smallx], 63, 6) and MyStr = Mid(["_smallx"], 63, 6) The ...
0
votes
1answer
46 views

How to use QGIS field calculator to delete style code?

I am struggling with following issue: How to delete style code before id codes x.x.xx.. and the }s in the end? Examples below. Any help appreciated! {\fArial|b1|i0|c0|p34;A.B.11} ...
4
votes
1answer
172 views

How to use Field Calculator to assign values to only Odd (or Even) page fields for Data Driven Pages?

I am creating a map book but do not want the page numbers for each map page to be on the same side (since its printed double sided), I need the page numbers to be placed on opposite sides? I am using ...
2
votes
2answers
255 views

Convert from Julian Date to Calender Date in Field Calculator

Does anyone know of a way to convert from a Julian date to a regular calender date in either QGIS or ArcGIS field calculator? Thanks...
0
votes
0answers
45 views

Calculating rows in a attribute table of a point shape with QGis or Saga

I have a point shape with an attribut ("test"). I need to calculate the sum of the 1st four (id 1-4) "test" values and then the next 4 (id 5-8). Is there a chance to calculate this with the field ...
1
vote
1answer
56 views

Arcgis 10 assign values to field based on values in other field [duplicate]

I have a table with two fields A and B, and i want fill field B with "some values" from field A: FieldA: 123456_CC; 123_D; 1234567_AB; 123456768_F I just need the "text" that is associated with the ...
0
votes
1answer
478 views

Why does Field Calculator say failure during processing, check geoprocessing results window for details? [duplicate]

I am using the Field Calculator and keep receiving the following error: 'There was a failure during processing, check the geoprocessing results window for details'. I am not very tech-savvy but I have ...
0
votes
1answer
114 views

Parsing field in field calculator using Python

I have field1 which has a values of "A_B" (example). I created two fields out of this, values to the left of the underscore go in fielda and to the right of the underscore go in fieldb. I used the ...
0
votes
1answer
883 views

how to use the TRIM function in field calculator

I need to remove leading spaces in a field in my attribute table, but not how to do it from the field calculator
2
votes
2answers
92 views

What's the use of the buffer function in field calculator?

I'm trying to find out how the buffer command in the filed calculator works. I tried to create a new field to my point shapefile (integer) with the following: buffer ($geometry, 100) but no ...
3
votes
1answer
303 views

Using Python in Field Calculator to compare two fields

I'm trying to use field calculator to compare two fields in a table of tax parcel data, Land Value (LAND_VAL) and Improvement Value (IMPRVT_VAL). My goal is to determine (1) Parcels with land value ...
2
votes
4answers
173 views

Field calculator Python else statement question

The codeblock below is run on Field1 and calculates Field1 to equal Field2 if they are not equal. Else it returns Field1. My question is, does the else statement actually recalculate Field1 to equal ...
1
vote
0answers
21 views

Can a joined-layer have its attribute changed depending on what layers are selected/deselected?

Using QGIS, I have a polygon-grid layer which covers everything, Layer_All joined with 2 other grid layers: Layer_1 and Layer_2, both of which intersect at various points. I would like Layer_All to ...
3
votes
1answer
79 views

How do I add a field to a table using the QGIS graphic modeler?

I was wondering if anyone could help as I'm struggling to get anything out of the QGIS graphic modeler. For info I have no programming skills whatsoever. I need to be able to add a new field to an ...
2
votes
1answer
81 views

Decimal Degree data erases itself between edit sessions in QGIS

I have a shapefile with point data. I calculate the $x and $y of the points successfully I save the changes and close the edit session. Once I reopen the attribute table, the data after the decimal ...
1
vote
1answer
329 views

Null value error with Python in field calculator

I'm trying to calculate the angle between two line segments in ArcMap 10.0. I have a point shapefile, so I'm using the xy coordinates of 3 successive points to calculate the angle. I'm trying to use ...
0
votes
1answer
125 views

CalculateField_management - updating fields with X and Y coordinates for start and end of line

I've searched all the help documents and can't see where my script is going wrong. I've tried adding the fields as FLOAT, replacing "PYTHON_9_3" with just "PYTHON" but it just doesn't work. The ...
0
votes
1answer
96 views

Python field calc syntax error

The screenshot shows a calculate field tool in modelbuilder. The error I'm getting is invalid syntax line 1. I can't see any issues w/the syntax so I'm hoping someone out there can help. It ...
1
vote
1answer
73 views

Python in ArcGIS, CalculateField_management, updating with single value

I have a float field which I want to simply update all values with 1. I can easily do this within the field calculator but I have started using python today, what is the syntax to simply update a ...
2
votes
1answer
51 views

Expression to create and populate column based on filtered fields

I wanted to create a column and populate it with data based on data from other fields. If column_1 contains fields which has similar string (eg. field_1 = "Country: UK", field_2 = "Country: US", ...
1
vote
1answer
68 views

Create and immediately update field using Field Calculator

You can create fields and once created, populate them with data using the Field Calculator. But can you do both at the same time using an expression? Or must you do it in 2 steps?
-1
votes
1answer
114 views

IF-Statement in Field Calculator [closed]

I want to use an IF/ELSE-Statement to define a field in the attribute table of my raster. Therefore I have a field "VALUE". The condition should be: If "VALUE" < 4 ...then use die field "A".....if ...
3
votes
0answers
69 views

Using Field Calculator to Convert Data Type In Field

I am trying to convert a field that is listed as "String" because it was imported into QGIS as a CSV (rural poverty population percentages by county in NC). I need to convert the percentages field ...
1
vote
1answer
28 views

Does ArcGIS Desktop have conditional function useable in field calculations?

Does ArcGIS / ArcView 10 have a conditional function, e.g. ifx(test,if_T,if_F), that could be in-lined in field calculations?
2
votes
2answers
123 views

Conditional field calculator expression

I need to calculate the PIPEID field to equal the G_KEY_COMP field if PIPEID is null or PIPEID and G_KEY_COMP do not match. I think the first condition of the PIPEID being null is covered by the ...
-1
votes
1answer
77 views

Why does dividing two decimal field values using Field Calculator return/write Integer? [duplicate]

I have fields in my datasets such as HR60, HR70, HR80, HR90 When I tried to use field calculator using the following [HR70]/[HR60], all I got was 1, 2, 3, 4 as my values. Last time I checked ...
2
votes
1answer
137 views

Field Calculator: return two or more field value

I trying to return three field values in same If Statment and conecate them, but i Get NULL value insted of the conecated fields getClass (!InDiameter! , !OutDiameter! , !TheridDiameter!, ...
0
votes
1answer
35 views

Wich is the way to create serial field following alphabetical order with QGIS?

I have a field with names, a string field, and I want to create another one with serial content following the alphabetical order. I have this: -------- |Field1| -------- | B | -------- | C ...
3
votes
2answers
410 views

Round decimal number in ArcGIS10.1

How can I round the decimal number in a table in Arcmap: e.g. how can I set it to 2.60?
5
votes
0answers
208 views

How to set order of operations for Field Calculation in Network Analyst Evaluator Dialogue? [closed]

I desire to have a ratio calculated each time I create a new route. To get this ratio, I created and populated a field that multiplied the length of each segment by a designated number from 1-5, ...
0
votes
1answer
46 views

Formatting Cells in ArcMap

I am trying to join tables together and need the PLSS to line up correctly. In my table with geometries I have "CO060020N0650W0SN330" in a field. I want to make a new column and make it say 2N65W33 ...
0
votes
2answers
339 views

Field calculator error and Geoprocessing results window empty

I need to use the field caculator for a new field that I have just added but I keep getting the following error: The problem is that when I open the Geoprocessing Results window is just completly ...
6
votes
3answers
2k views

How to replace non-English characters in attribute tables using Python?

I have a few shapefiles where some of the attributes contain the non-English characters ÅÄÖ. Since some queries doesn't work with these characters (specifically ChangeDetector), I tried to change them ...
8
votes
5answers
331 views

Print out the properties of the attribute table in qgis?

I have to merge a lot of shapefiles into one great shapefile. So I want to compare the properties of the attribute tables to see if there are differences between the tableproperties of each shape ...
1
vote
2answers
46 views

How can I populate a field of the polylines to indicate if they intersect?

I have two feature classes, one ploylines, one a buffer. How can I populate a field of the polylines to indicate if they intersect?
1
vote
0answers
34 views

How to replace accented strings in attribute tables using Python or VBA ArcGIS 10.2 [duplicate]

I need to replace accented words, into the Field Calculator, to the same non-accented ones. For example: María ---> Maria Need some help with this VB Code: Dim data as integer Dim contador Dim ...
1
vote
2answers
411 views

area values determined with field calculator become null when saving

using field calculator in Qgis 1.8.0 to get the area, it shows just right at first but when I save it, the values become Null. help please
2
votes
2answers
128 views

python add fields that may have NULL values

I would like to use python to calculate a field (short integer) using other fields (short integer) present in the table. In some cases these fields may have NULL values for one or more of the fields. ...
2
votes
2answers
158 views

How to trim strings in Field Calculator?

I am currently working on a County plat book and am in the process of prepping the "Owner_Nm" field that will serve as my annotation layer. I am trying to whittle down the owner names, based on ...
5
votes
3answers
1k views

calculating a field in which null values may be present

I would like to calculate a field (short integer) using other fields (short integer) present in the table. In some cases these fields may have null values for one or more of the fields. For example, ...
2
votes
1answer
79 views

Arcpy Calculate Field Formatting Syntax

I am trying to field calculate a double field (PID) to a new string field (PIN). Using: qry = '"139-{}".format(!PID!)' arcpy.CalculateField_management(out, "PIN", qry, "PYTHON") Given a PID = ...