I have a model that iterates a process for each unique field value of [Type] field. The model aggregates polygons of a like Type, and at the end of the model a new field is created and populated with each unique [Type] for the aggregation using "%Value%" from the output of the iterator. These iterations are then appended and contained within a newly created feature class.

I would like to retain this attribution for each set of polygons(original [Type] value), but I would like to include another set of values to the iteration. That is, instead of iterating through each unique [Type] value, I would like to iterate through [Type] AND [Grouping]. The [Grouping] field is a simple Short field, containing only two unique values. Ideally, the aggregation would aggregate polygon clusters with like [Type] AND [Grouping] values, yet attribute the polygon with a single [Type] value, as well as a field with a [Grouping] value.

The problem that I am running into is that if i concatenate the two fields in before running the iterator based on the concatenated field, the value output is concatenated, and my "%Value%" output no longer is correct for populating the field at the end of the model. Is there a way that I can use an iterator to select [Type] AND [Grouping], yet call on the [Type] value of the selection to populate the field at the end of the model?

After concatenating, and using %Value%, change that to (%Value%)-(Length of that grouping field). In order to subtract those last 2 (or however long the actual grouping field is) characters, just calculate the total length of the concatenated %Value&, and do a "Left(Type, length - 2)" and you'll end up with just the Type field with that end part cut off. This of course only works if that "Grouping" field is the same length for all values. If the "grouping" field is different lengths, it can still be done, but a little more complicated.
–
MLowrySep 7 '11 at 12:33