Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [error-000539]

Use this tag for Questions which are related to the "000539" error returned by ArcGIS Desktop and ArcGIS Pro.

0
votes
1answer
91 views

ExecuteError: ERROR 000539: Error running expression: rcexec()

from arcpy import * arcpy.CheckOutExtension('Spatial') arcpy.env.workspace=r'D:\work\USA' #pathway to all rasters in workspace directory rasters = arcpy.ListRasters('*.tif') # Local variables: ...
1
vote
4answers
329 views

Calculations in if statement

I want to perform a simple calculation with the Field Calculator using this piece of script (note that all the elif statements are attempts for another syntax and non of the worked): def change(...
0
votes
0answers
39 views

ModelBuilder and Raster Calculator Error 000539?

I'm currently working in ModelBuilder trying to use the Raster Calculator and I keep getting the error message 000539. The error according to ESRI says it's an invalid pathway. What I have circled ...
0
votes
2answers
72 views

Concatenate fields (double and string) to create address using arcpy

fields: STNUM = double STRDIR = string STRNAME = string STRTYPE = string Tuple and s.format I have tried: arcpy.CalculateField_management (newparcelsUTM, "SiteAddress","{0} {1} {2} {3} ".format('!...
2
votes
1answer
381 views

if/then with VBScript in ArcGIS Field Calculator giving Error 000539: SyntaxError: invalid syntax?

What is wrong with this VBscript in the field calculator? ColumnC= if [ColumnB] > 0 then [ColumnC] = [ColumnA] / [ColumnB] endif Each time I receive this syntax error message: Error ...
0
votes
2answers
118 views

Error 000539 running multiple con expressions in raster calculator in ModelBuilder?

I am using Raster Calcuator in ModelBuilder with ArcMap 10.5. I used Get Raster Properties to extract Standard Deviation and Mean from a previously calculated raster. I would like to use Raster ...
0
votes
1answer
45 views

Getting Python Script Error 000539?

I'm attempting to create a tool that gives me the next available manhole number in a particular system. The manhole numbering structure looks like 1124-060E and therefore is a string field. Since ...
4
votes
1answer
1k views

Scale raster in ArcGIS using raster calculator

I have a raster with values ranging from 0 to 8991130624. This raster is actually the result of a cost distance analysis. I want to scale the raster to range from 0 to 1 and take the inverse? so ...
1
vote
1answer
278 views

ArcPy Raster Calculator error “ 'str' object has no attribute 'save' ”

I converted a model into python script and tried to run it. It gave me an error when it gets to the raster calculator process.The message says "str" object has no attribute "save". See picture below. ...
5
votes
1answer
201 views

Calculating Polsby-Popper Score Using ArcGIS Pro Field Calculator gives ERROR 000539?

This operation is using the Field Calculator in ArcGIS Pro 2.1. I am trying to calculate the Polsby-Popper Score for Congressional Districts. I have calculated the Geodesic Area and Geodesic ...
1
vote
1answer
122 views

If/Then python script in Field Calculator not working

I'm working in Modelbuilder. I have a polygon in which I calculate the shape centroid in decimal coordinates (field called LONG_CENTR). Then I add a field (called FAJA) and I want to use a Field ...
1
vote
1answer
55 views

Using ModelBuilder with Field Calculator gives SyntaxError?

I am brand new to coding, have no background at all. Basically I have about 200 tables with the same info listed under slightly different attribute table headings and I am trying to rename them to ...
1
vote
3answers
2k views

Using Raster calculator in Modelbuilder ArcGis 10

I am using Modelbuilder to calculate several rasters with different parameters for each grid cell. One of the final steps is to calculate the log of one of the rasters using Raster calculator. ...
0
votes
0answers
163 views

Raster Calculator - Error 000539: Error running expression

I'm trying to simply combine 5 different rasters in raster calculator to do a site suitability analysis using this map algebra expression: "bo_reclasstemph3" + "bo_reclassph" + "bo_raster_precip" + "...
0
votes
1answer
46 views

Converting Angles in a File Geodatabase Table - via Field Calculator's Python

In a file geodatabase table, I have an attribute called 'NEAR_ANGLE' created via the "Generate Near Table" tool that I'd like to convert to a 0-360 degrees format. I've created an attribute called '...
0
votes
1answer
227 views

If-then-else Statements and string errors?

I'm defining a string field based on contents of another string field. Simply put, if the contents of field A contain this value, then fill field B with this text. It throws a string related error ...
1
vote
1answer
50 views

CalculateField_management, python Toolbox

I am trying to fill a field and I am using arcpy's CalculateField_management function. I want to fill the new field with the name of the shapefile, so I am using arcpy.Describe. But when I run the ...
0
votes
1answer
100 views

Calculating Field Chosen by arcpy.GetParameterAsText(1) gives ERROR 000539?

I add a parameter CampoConfere = arcpy.GetParameterAsText(1) which get a field from Tabela_Base to calculate in the next steps from the code. The Scripts works well until the Calculate Field Step when ...
0
votes
1answer
218 views

ERROR 000539: Error running expression_NameError: name 'shape title' is not defined

I'm trying to get the title of the shapefiles or feature classes that are in a workspace (folder or GDB), into the field as a Name in python. I know this is easier in modelbuilder by adding %Name% in ...
-1
votes
1answer
149 views

Python Script error in function ERROR 000539: SyntaxError

I am receiving the following error; is it a simple syntax issue with the Calculate field because I'm not seeing anything missing. ExecuteError: ERROR 000539: SyntaxError: unexpected EOF while parsing ...
1
vote
1answer
246 views

Calculate field Error 000539

I am brand new to the world of GIS and I have never used Python. I tried running a calculate field command within the geoprocessing toolbox (not python) and I got an error. I did a bunch of split ...
1
vote
0answers
76 views

Map algebra raster calculator

I am attempting a GIS tutorial on land change analysis between two rasters. I have set the extent and raster analysis to what I have been given and used the expression below. However, it is not ...
3
votes
1answer
5k views

Receiving error 000539 from CalculateField_management?

I am trying to add (ie "Author", "LastUpdated") to feature classes within a gdb and then populate each of those fields. I have been able to get my code to run properly for the numerical field but I ...
1
vote
1answer
209 views

Error - Not defined - Arcpy

I'm trying to add a part of my filename into a field that i'd created, but it comes with the following error: Traceback (most recent call last): File "Z:\04 - Temp\Charles\NDVI_tempo\...
2
votes
0answers
158 views

ERROR 000539 from ModelBuilder with Raster Calculator? [closed]

I'm trying to do a math operation in raster calculator using the rasters from other two raster calculators. My calculation is a simple NDVI formula: (rastcalc4 - rastcalc3)/(rastcalc4 + rastcalc3) ...
1
vote
0answers
203 views

Using Calculate Field to get acreage in ArcGIS ModelBuilder? [closed]

Update: Problem Solved I fixed it. In the Calculate Field Tool within Model Builder, I entered "!shape.area@acres!" . That resolved the issue and the model now produces the same results as the python ...
13
votes
8answers
32k views

Removing return/newline (\n) character from Field using Python and Field Calculator?

I have a geodatabase table with a field that I'm trying to remove return characters (new line). I found this post (How can I remove (chomp) a newline in Python?) of how to do it, however it is not ...
2
votes
1answer
91 views

Exporting attachments from FGDB and populating field with picture path

I am trying to export attachments from fGDB and populate fields with the picture link path. I created a script following these instructions http://support.esri.com/en/technical-article/000014520 ...
2
votes
2answers
2k views

Concatenating strings from two fields using Python in ArcMap Field Calculator?

I'm new to Python scripting and I don't understand what is wrong with this code. I want to concatenate the string values from GRID1MIL and GRID100K. I've created a text column MGRS to begin with. I ...
0
votes
1answer
237 views

Reclassifying slope using ArcGIS raster calculator?

I have a slope raster in degrees and would like to reclassify it the layer with the raster calculator. my criteria: slope between 15 & 20 receive a 1 slope greater than 20 receive a value of 2 ...
1
vote
1answer
550 views

Raster calculation with multiple rasters using ArcGIS Desktop?

I have three rasters: Raster1: resolution 25x25, floating point. Value of "1" when it is true, value of -9999 when it is false (only this two values) Raster2: resolution 25x25, floating point. Only ...
1
vote
1answer
508 views

ArcGIS Raster Calculator won't work in main model

I've created a sub-model in ArcGIS, which stretches my raster data to new values. The strange thing is, that the model works, if I run it itself - as soon as I implement it in the main model, I get ...
2
votes
1answer
2k views

ArcMap raster calculator error 000539

Using ArcMap 10.3, I am trying to perform map algebra on a raster with 2013 annual PRISM precipitation for the U.S. (http://prism.oregonstate.edu/recent/). The raster has 1 band an is floating point. ...
3
votes
1answer
537 views

Replacing multiple characters at once

I have a problem with replacing in field calculator. For some reason my Python parser is not working. So I'm going to use VB and having tonns of this Replace([field],"x","y") Replace([field],"z","a")...
1
vote
1answer
339 views

Embedded quotes in arcpy.CalculateField_management expression

I'm using arcpy.CalculateField_management to populate a field. The expression: "'https://anystate.gov/someportal/DisplayQueryResults.aspx?Prompts=Spill%20Number="!ID!"&Database=OfficeDocs&...
0
votes
1answer
570 views

Raster Calculator with conditional arguments?

I am trying to create a binary raster using the Raster Calculator in ArcGIS 10.2. I have a raster with ~20 different values, but I'm only interested in cells where the value = 10. I've been using the ...
1
vote
1answer
413 views

ERROR 00539: Error running expression:rcexec()

I'm trying to run a batch operation on raster calculator. The expression I use is this: (Float("92011033_B2.tif") - Float("92011033_B5.tif")) / (Float("92011033_B2.tif") + Float("92011033_B5.tif")) ...
1
vote
0answers
236 views

Error 000539 in ArcGIS Desktop?

I am using Raster Calculator in ArcGIS 10.4.1 in order to substract two raster surfaces. However, when I substracted the two surfaces an error 000539 was appeared! I tried to adjust the two surfaces ...
1
vote
0answers
385 views

ArcGIS Raster Calculator Error 000539

I am getting the error-000539: Error running expression: rcexec(). I've seen that other people have this same issue but I am not sure how to fix mine. I just want to average the values of 10 rasters, ...
3
votes
1answer
335 views

Get multiple values from summary tables in Model builder

I working with ModelBuilder and I have two summary statistics tools, with 'case fields' that have multiple sum values, I want to use these sum values from one table and divide the sum values from ...
1
vote
1answer
217 views

ERROR 000539: Error running expression:rcexec ()

I have got this error when tried to make slope less than 20 degree through Raster Calculator. One day before I installed Python 2.7.13 and after, this error appeared. When I delete the downloaded ...
2
votes
1answer
339 views

Select Data won't work… Parameters are not valid in ArcGIS ModelBuilder?

I'm creating a model in the ArcGIS 10.3 ModelBuilder and have problems to get the select data tool to work. At first the complete model: IHS-Klassifizierung With the Select Data tool (Input Data ...
2
votes
1answer
1k views

Calculating centroids of polygon using ArcPy?

I am trying to calculate the centroids of a polygon and add the x- and y-coordinate to their respective fields: arcpy.env.workspace = r"C:/..." input_fc = "shapefiles/precincts_v.shp" arcpy....
4
votes
1answer
2k views

Why is arcpy.CalculateField_management() writing 1899-12-30 00:00:00 instead of expected date?

I'm using ArcGIS 10.3.1 for Desktop to test before writing an answer to Entering date with arcpy.GetParameterAsText()? I have written the test code below that I am running against a test feature class ...
0
votes
1answer
171 views

How can I refer to two tables in ArcPy's CalculateField_management? [closed]

I tried to refer to the different table's fields just like I saw in How to Calculate Field in joined table using ArcPy? but it doesn't work. There are two tables in my example. I have created table "...
1
vote
2answers
154 views

Printing name of field with highest value?

I am trying to find the field with highest area value in each row of the 5 fields. Now I have found the highest value. But it doesn't really do me any good if I couldn't find which field is that max. ...
2
votes
1answer
84 views

ArcGIS Field Editor if/else syntax with python

I am just starting with Python and ArcGIs so here is my question: I have the column "DB_Low" (Type "Long") and want to fill a new column by changing values. The new column will be a Float-Type field. ...
2
votes
0answers
921 views

Cause of Field Calculator UnicodeEncodeError: 'ascii' codec can't encode character u'\xf6' in position 5: ordinal not in range(128)? [closed]

def Befahrung(value1,value2): if value1 is ' ': return ' ' else: return "G:\\Example\\" + str(value1) + "\\File_" + str(value2) + ".pdf" I try to create a field with a hyperlink. It works ...
1
vote
1answer
369 views

How to tranform a column field into a list using Field Calculator

I'm trying to make a simple field calculation with ArcGIS 9.3: New field = Old field - Old field(first value) which in Calculate Field with python code should be Expression: !Old field! - first ...
0
votes
1answer
2k views

Problem with raster calculator [closed]

When working with raster calculator there is an error 000539? The program failed to create a common raster map. I don't know what to do. I did the same in school without any problems. But now, on my ...