I built a model that does some basic selection by attributes and then refines that selection by adding other points within 500ft and then removing the originally selected point from the selection set and then it outputs everything to visible layers in the session. It works great! I get one selected point as the “lottery selection” and then I get a bunch of other points within 500ft of that are now “Invalid Selections”. I can open that layer as a table and it’s exactly what I need.
Now I want to feed it MULTIPLE values for the “SQL Expression” and have it reiterate through those values one at a time and output the results of the "invalid selections" individually to an excel file. I've tried a bunch of thing but either I get ALL the records in the layer output to the individual excel files or ONLY the last result in the list over and over again in the excel files.
I tried using the multivalue SQL iteration (above image) and I just couldn't get it to work. I tried switching the expression to a “list” of values and it didn't work either. Suggestions welcome!
It's quite difficult to help you as you have renamed all the tools so we have no idea what they were! Personally I would avoid doing that as other users will not be able to understand the model. It's OK to rename the inputs/outputs.
So assuming your first tool in your second model is a Select by Attribute (what you are calling Update Lottery Selection) then you seem to have connected it where I think it should have been an inline substitution.
In my model see how I call the iterator value in the SQL expression