Select to view content in your preferred language

The process did not execute because the precondition is false.

462
5
Jump to solution
08-02-2024 07:49 AM
Labels (1)
ashKGS
by
Emerging Contributor

Hey everyone,

I'm trying to build a model to automatically generate radial lines emanating from a point. I have used the CalculateGeometryAttributes tool to generate x and y coordinates for a single point. Then I used the GetFieldValue tool to extract the x and y coordinates. These values are used as preconditions and inputs for a CalculateField tool, which adds these points to a table. But I keep getting the "The process did not execute because the precondition is false." error message.

Here's a copy of the error. As you can see, GetFieldValue was able to successfully extract the x and y coordinates from CalculateGeometryAttributes , so there is no reason for the precondition to fail.

Executing (Calculate Geometry Attributes): CalculateGeometryAttributes points "Point_X POINT_X;Point_Y POINT_Y" # # PROJCS["WGS_1984_Web_Mercator_Auxiliary_Sphere",GEOGCS["GCS_WGS_1984",DATUM["D_WGS_1984",SPHEROID["WGS_1984",6378137.0,298.257223563]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Mercator_Auxiliary_Sphere"],PARAMETER["False_Easting",0.0],PARAMETER["False_Northing",0.0],PARAMETER["Central_Meridian",0.0],PARAMETER["Standard_Parallel_1",0.0],PARAMETER["Auxiliary_Sphere_Type",0.0],UNIT["Meter",1.0]] "Decimal Degrees"
Start Time: August 2, 2024 10:45:02 AM
Succeeded at August 2, 2024 10:45:03 AM (Elapsed Time: 0.38 seconds)


Executing (Get X Value): GetFieldValue points Point_X Double 0
Start Time: August 2, 2024 10:45:03 AM
Succeeded at August 2, 2024 10:45:03 AM (Elapsed Time: 0.01 seconds)


Executing (Calculate X Field): CalculateField "[filepath censored]\Default.gdb\Template_noCoords" Point_X -105.49058464 Python # Text NO_ENFORCE_DOMAINS
Start Time: August 2, 2024 10:45:03 AM
The process did not execute because the precondition is false.
Succeeded at August 2, 2024 10:45:03 AM (Elapsed Time: 0.00 seconds)


Executing (Get Y Value): GetFieldValue points Point_Y Double 0
Start Time: August 2, 2024 10:45:03 AM
Succeeded at August 2, 2024 10:45:03 AM (Elapsed Time: 0.01 seconds)


Executing (Calculate Y Field): CalculateField "[filepath censored]\Default.gdb\Template_noCoords" Point_Y 50.85320402 Python # Text NO_ENFORCE_DOMAINS
Start Time: August 2, 2024 10:45:03 AM
All the inputs are not current.

 

This is what the model looks like, in case that helps find a solution. 

Screenshot 2024-08-02 104920.png

0 Kudos
1 Solution

Accepted Solutions
SiqiLi
by Esri Contributor
Esri Contributor

Could you please try to change the Get Field Value tool Data Type parameter from "Double" to "String"?

When the Data Type is set as Double, Long, or Boolean, the precondition link considers value 0 as false.

SiqiLi_1-1723565562834.png

 


Executing (Get X Value): GetFieldValue points Point_X Double 0
Start Time: August 2, 2024 10:45:03 AM
Succeeded at August 2, 2024 10:45:03 AM (Elapsed Time: 0.01 seconds)


Executing (Get Y Value): GetFieldValue points Point_Y Double 0
Start Time: August 2, 2024 10:45:03 AM
Succeeded at August 2, 2024 10:45:03 AM (Elapsed Time: 0.01 seconds)

 




View solution in original post

0 Kudos
5 Replies
BobBooth1
Esri Contributor

It may help to lay out your model from left to right so you can more easily see the sequence. 

It looks as though that branch that starts at Radial Lengths Table Template doesn't get to run because it depends on things that have not executed yet.

0 Kudos
BobBooth1
Esri Contributor

Might also look at this Python toolbox.

https://github.com/Esri/military-tools-geoprocessing-toolbox

0 Kudos
ashKGS
by
Emerging Contributor

I've reorganized the layout, hopefully it's a bit more clear. There are pre-condition arrows to force other processes to run before the radial lengths table template can be used. 

ashKGS_0-1723210775459.png

The funny thing is that this model actually worked perfectly before, but for some reason doesn't work anymore. Here's the correct output it generated previously:

ashKGS_1-1723210893462.png

If you know of any pre-built ESRI tool that can achieve this same result, please let me know! I have no clue what the problem is with the model or how to fix it because it worked perfectly fine before, but doesn't work anymore.

0 Kudos
SiqiLi
by Esri Contributor
Esri Contributor

Could you please try to change the Get Field Value tool Data Type parameter from "Double" to "String"?

When the Data Type is set as Double, Long, or Boolean, the precondition link considers value 0 as false.

SiqiLi_1-1723565562834.png

 


Executing (Get X Value): GetFieldValue points Point_X Double 0
Start Time: August 2, 2024 10:45:03 AM
Succeeded at August 2, 2024 10:45:03 AM (Elapsed Time: 0.01 seconds)


Executing (Get Y Value): GetFieldValue points Point_Y Double 0
Start Time: August 2, 2024 10:45:03 AM
Succeeded at August 2, 2024 10:45:03 AM (Elapsed Time: 0.01 seconds)

 




0 Kudos
ashKGS
by
Emerging Contributor

Thank you! That seemed to solve the issue.

0 Kudos