2

I've made a python tool that requires the user to establish which state to select within an input's table (the "Prepared Footprint"). However, once the user drops in the layer and tries to write the SQL statement to select the state which is contained in the state field of the Prepared Footprint, there are no available fields to select from.

enter image description here

Is there some option within the properties of the python script tool that will allow the Query Builder to populate the fields and attributes from the input layer like the native Select by Attributes in ArcMap? If not, how might I code this into my source script to feed fields and their attributes to the Query Builder of the "State" parameter?

(experience level with building tools: Beginner)


EDIT: Here's a screenshot of the tool's parameters. When I select "State" and try to change the "Obtained from" paramter property nothing happens. There's no drop down, no cursor, nothing but a highlighted row for "Obtained from". Has anyone ever had this problem before?

enter image description here


EDIT: Found the problem. A "Layer" data type cannot be used as the input for "Obtained from". Feature Layer works instead for this case.

enter image description here

asked Jan 17, 2014 at 21:23
1

1 Answer 1

8

When you define the parameters for your script. For the "State" parameter, you have to set the "obtained from" parameter properties to "Prepared Footprint".

answered Jan 17, 2014 at 22:53
1
  • I see where this option is, but it's not letting me select anything. The "Obtained from" parameter property in the tool Properties is non-editable. Is this possibly a license issue? Commented Jan 21, 2014 at 16:10

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.