1

I need to Calculate a Field with modelbuilder, but first I want to make a join with 2 tables, and only after that join I have the parameters to calculate the field. While constructing the model I need to write the expression to calculate the field but I don't have the fields that I need yet because I still didn't make the join. How do I solve this?

asked Jun 3, 2015 at 13:50
1
  • Have you tried adding a Feature Class to Feature Class stage after the join? Commented Jun 3, 2015 at 14:35

2 Answers 2

1

This is a limitation of model builder, a real chicken and egg problem! You can do one of two things:

  • If the model is "static" in that it's always the same tables being joined then you can simply write the field calculate expression. Don't bother trying to use the interface just type it in. You will need to be careful with the syntax structure and included the table name. I would create create the joins manually pretend to do a field calculate and build the expression and copy that down then add that to the field calculate in the model.
  • Another way is to build you model with the joins, run that so the model elements are shaded to show that you have executed them THEN add the field calculate tool to model builder connect it and you should see all the fields to build the field calculate expression.
answered Jun 3, 2015 at 22:06
1
  • I'll pick the second option. But every time that I run the model i'll have to do that? Run only with join and then add the field calculate tool? Commented Jun 4, 2015 at 11:36
-1

In the Model Builder, run only the join operation. The needed fields will be available in the output data for running your Field Calculation.

Mapperz
50.6k9 gold badges76 silver badges133 bronze badges
answered Jun 3, 2015 at 15:35
0

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.