1

I'm using ArcGis 10.2.2 and I'm creating a model in ModelBuilder.

I want to know how I can list the attributes of a field and then make a selection for each unique attribute using Python.

I have a shapefile with the field "Name". Example:

name | 
----------- 
BB 
BB 
AB 
AB 
C 
C 

I want to list BB, AB, C, etc.

I want to construct a list and then use that list to make a selection for each of the unique values. For example, "Name" = 'BB'.

4
  • 3
    Your question is confusing, you are mixing up terms between your title question and the body content (field vs attribute field values, modelbuilder or python?).
    – artwork21
    Oct 27, 2014 at 16:35
  • the goal is to automate the base is modelbuilder if there is no option to use a tool to perform this could be the use of Python Script
    – user22547
    Oct 27, 2014 at 20:36
  • Would you be able to edit your question to revise it with that clarification, please? Also, can you describe in more detail what the inputs and outputs from your model/script would be?
    – PolyGeo
    Oct 27, 2014 at 21:51
  • thanks, this solved with the tool (Iterate Feature Selection)
    – user22547
    Oct 27, 2014 at 22:05

1 Answer 1

4

You may use Iterate Feature Selection in ModelBuilder:

Iterates over features in a feature class.

2
  • I do not understand I could explain
    – user22547
    Oct 27, 2014 at 16:30
  • Click on the hyperlink for Iterate Feature Selection within may answer, it will provide you additional content and case examples.
    – artwork21
    Oct 27, 2014 at 16:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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