Select to view content in your preferred language

ArcGIS Pro 3.1.2 - How to use inline variable in Calculator Expression in ModelBuilder?

353
0
11-03-2023 05:32 AM
VincentLaunstorfer
Frequent Contributor

Hi,

I designed a model in ModelBuilder which is using a For loop to loop through years... And using the years to make Layer by Attribute selection.

As the variable 'Value' (which represents the years) is changing during run-time of the model with the 'For' loop, I need to use this variable 'Value' as an inline variable (enclosed in percent signs) in the expression to make the Layer by Attribute selection.

However, the geoprocessing tool Layer by Attribute do not accept the inline variable. Instead, I tried to use a Calculator Expression variable, but it does not seem to work either.

Is there any way to use an inline variable to make a Select by Attribute expression?

ModelBuilder_InlineVariable_in_CalculatorExpression.png

 

0 Kudos
0 Replies