Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

This is similar to Modelbuilder - If precondition is false, continue iterating next input but I want the iterate tool to run to collect all the values and only then continue to the merge. Any ideas? Currently it just runs the whole process for each file (which works but takes much longer than if the merge is done only once) or I have to manually break the collect-merge link, run the iterate, reconnect the collect-merge link and then continue running the model which is a pain as it is a lot of towers that need processing and this collect values-finish getting all values and then continue will be required in other models as well.

enter image description here

I tried the "Select Data" tool as well but this doesn't allow for wildcard searches like the Iterate does -my Iterate has the "_Graded*" as the search param as the gdb included many other files related to each tower chunk.

My STOP is set to "True" (tried false as well). I also tried to connect the Stop to the Iterate instead of Collect values but same result.


I just created a python tool for this and it collects all the values but it passes them back to the model as a long list -how can I get it to output in a proper format?

    import sys, os, arcpy



arcpy.env.workspace = GDB
for item in arcpy.ListFeatureClasses('*'+Search+'*',Type):
    #arcpy.SetParameterAsText(3, item)

arcpy.SetParameterAsText(3, List)
arcpy.AddMessage("List: "+str(List))

enter image description here

enter image description here

share|improve this question
Is there a reason you cant just do the processing for the Merge in the script? – theJones May 15 '12 at 23:39
There are other processes running after this and I would like to get the list input process working as I have a need for it in other models as well. – GeorgeC May 16 '12 at 10:26
Ah snap! That makes it harder. First guess looking at the screen shot is that ListFeatureClasses returns the "second half" of the fc. What I mean is that is knows the env setting and does not automatically join it. I would use the full workspace path in the python list.… – theJones May 16 '12 at 17:45
Check out the section Advanced use of model iterators on this page.… – theJones May 17 '12 at 22:36

You need to create a submodel and connect that to the Merge tool. For example:

The submodel (SubModel1)

enter image description here

The full model

enter image description here

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.