Bug in Modelbuilder iterators when run as tool

Discussion created by curtvprice Champion on Jul 25, 2014
Latest reply on May 20, 2015 by curtvprice

I just found a bug in 10.2.1 / 10.2.2 that has already been logged but is not fixed. Thankfully it is marked Severe!


[#NIM103740  When a model with an Iterator is run from within the Model editor, it will complete correctly, but overwrites the outputs when run as a tool. ]


The issue I ran into is that when you use an iterator output variable in the output name variable (for example %outworkspace%/%name%) it gets set in iteration 1 and 2, but after that it reverts to the value from iteration 1. In my test example, my inputs are pp01.txt, pp02.txt, .. pp05.txt and are read correctly, but the output name variable is set to.









This is quite a show stopper.


The only workaround at this time seems to be to not run the model as a tool.