Hi all,
I have a question about using selected features in an analysis tool. I can't quite figure out how to make this work.
If I use the select tool to select let's say 10 houses from a building layer, I want to be able to take that building layer and use as an input to for instance the buffer tool..
But when I do that, it doesn't honor the selection.. it just takes all the features in the layer..
It would also be cool to be able to do the same with a GP/Web tool that you publish your self
Do anyone know a solution?
Solved! Go to Solution.
Yes we have found that some ways it works and some ways it does not. Super confusing to the user.
I have not made a breakdown of each of the different ways yet.
Not sure if it was just updated, but I had this issue until I realized I needed to use the action button on the selection widget to set the selection as the input for the GP tool, NOT the select layer button on the GP tool in the analysis widget. Also, the input is received as a "RecordSet" object, (parameter should still be set to "featureSet"), I'm still working on parsing the RecordSet, my next try is to dump the JSON into a python dictionary to access the feature attributes, but like the comment below, I only get the first few attributes, so I guess I'll be collecting the OIDs to query from my hosted layer in a query.
Hello all
We use the solution here to send some selected features to gp service.
The gp service gets the features but it looks like it does not gets all the attributes of each feature, only 2-3 attributes are send as part of the feature set.
Is that a bug?
Thanks
It is a known limitation if you use Select widget to pass as input as Select widget laze load the data.
A work around is add a Table widget to load all the attributes you need and use the same data action "Set as analysis input" from the table after you made selections