Skip to main content
Solved

ExpressionEvaluator Division

  • March 17, 2015
  • 1 reply
  • 44 views

danpaoly
Contributor
Forum|alt.badge.img+1
I am attempting to calculate the length in miles of line segments using the following 

 

(@Value(END_MEASURE)-@Value(BEGIN_MEASURE))/5280

 

 

I am receiving a warning as follows

 

 

ExpressionEvaluator_5: Failed to evaluate TCL expression: (-)/5280

 

ExpressionEvaluator_5: TCL Error Message: missing operand at _@_

 

in expression "(-_@_)/5280"

 

FileGDB Writer: The `Mileage' attribute could not be written. The containing feature has been dropped

 

 

If I remove the division I do not get the error.  I need to division to happen as the output needs to be in miles not feet.

 

 

thanks

 

Dan

Best answer by gio

Hi,

 

 

One or more inputs are EMPTY/MISSING/NULL.

 

In this case "(-)/5280" both operands are so.

 

 

TCL cannot handle an empty attribute in a expression.

 

This is because any expression is basically a string that will be parsed. An empty attribute results in an "empty" spot in the string wich causes a parsing error.

 

 

You must test for EMPTY/MISSING/NULL on all operands before sending thme to the ExpressionEvaluator.
View original
Did this help you find an answer to your question?
This post is closed to further activity.
It may be a question with a best answer, an implemented idea, or just a post needing no comment.
If you have a follow-up or related question, please post a new question or idea.
If there is a genuine update to be made, please contact us and request that the post is reopened.

1 reply

gio
Contributor
Forum|alt.badge.img+15
  • Contributor
  • Best Answer
  • March 17, 2015
Hi,

 

 

One or more inputs are EMPTY/MISSING/NULL.

 

In this case "(-)/5280" both operands are so.

 

 

TCL cannot handle an empty attribute in a expression.

 

This is because any expression is basically a string that will be parsed. An empty attribute results in an "empty" spot in the string wich causes a parsing error.

 

 

You must test for EMPTY/MISSING/NULL on all operands before sending thme to the ExpressionEvaluator.

Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings