Select to view content in your preferred language

Selection "Set as Analysis input" ignoring attributes and only bringing geometry to input of custom web tool

809
7
12-06-2024 01:33 PM
Labels (1)
tssaus
by
Emerging Contributor

EB Developer Edition v 1.16

 

I have a custom geoprocessing service (Python Toolbox) published to ArcGIS Enterprise, and it is being used in the Analysis widget within my Experience Builder.

 

 

When I make a selection on a layer with the Select widget, and use "Set as Analysis input" to my custom tool (the input parameter type is GPFeatureRecordSetLayer), it seems to only send the OBJECTID, Shape_Length, and Shape_Area attributes & its geometry. It ignores all other attributes. Since my tool depends on other attributes, it of course fails.

The layers I am using are feature services referenced to an SDE.

I know this isn't a problem with my code, because when I use the entire layer as the input, the attributes go to the tool as expected.

This seems like a bug? Is there a workaround for this, either within my script or in EB?

 

@Wei_Ying (I saw you are involved with this specific data action on other posts)

0 Kudos
7 Replies
Wei_Ying
Esri Regular Contributor

Hi @tssaus thanks for your feedback! Looks like a bug.

Would you be able to share with me the tool? 
And meanwhile, can you try loading your data in Table widget, and then select some records from table, to "Set as Analysis input " to the tool. See if the data attributes are passed correctly? 

0 Kudos
tssaus
by
Emerging Contributor

Hey! The attributes do pass correctly when sending from the Table widget off of a selection, and the tool functions as normal. It seems there is a bug with the select widget.

0 Kudos
Wei_Ying
Esri Regular Contributor

Thanks for confirmation. We will investigate the select widget issue. 

0 Kudos
Vara_PrasadM_S
Frequent Contributor

Hi @Wei_Ying,

We are also facing same issue. When we use 'Set as Analysis input' option from Select widget, the geo processing tool we configured in Analysis widget is not receiving data for all attributes from selected layer and subtypes and domains are also not available from the layer.

However, if we do same 'Set as Analysis input" from Table widget, everything is going fine.

Could you please let me know if its a bug, if there is any work around to continue to use Select widget as our users want to do selection from Select widget and use this 'Set as Analysis input' from Select widget only.

Thanks in advance!

0 Kudos
Wei_Ying
Esri Regular Contributor

@Vara_PrasadM_S wrote:

Hi @Wei_Ying,

We are also facing same issue. When we use 'Set as Analysis input' option from Select widget, the geo processing tool we configured in Analysis widget is not receiving data for all attributes from selected layer and subtypes and domains are also not available from the layer.

However, if we do same 'Set as Analysis input" from Table widget, everything is going fine.

Could you please let me know if its a bug, if there is any work around to continue to use Select widget as our users want to do selection from Select widget and use this 'Set as Analysis input' from Select widget only.

Thanks in advance!


Yes it is a known limitation that from Select widget the selected feature cannot pass all attributes. As the Select widget does not load all attributes for performance concern. And Table loads all attributes if you view it so the selection can be passed correctly. We will try to solve the limitation in future. 

Vara_PrasadM_S
Frequent Contributor

Hi @Wei_Ying,

Thank you for the information. Is there any way we can track the bug.

We have done a work around to fix this in our custom GP Tool and come out of this issue. However, we are facing another issue from Select Widget > Set as Analysis input.

1. Select features from "Select" widget => Use "Set as Analysis input" from Select widget, all working fine(with our work around in our custom GP tool)

2. Select features from "Table" widget => use "Set as Analysis input" from Table widget, all working fine

3. Select features from "Table" widget => use "Set as Analysis input" from "Select" widget, all working fine 

4. Select features from "Select" widget => use "Set as Analysis input" from "Table" widget. This flow is *not* working. Our tool has only one input parameter which is of Data Type - "Feature Layer". It is giving below error. I have add message statement as first line in our custom GP tool, that log itself is not visible. So, I feel before tool execution start itself, its failing.

  • Error: Invalid value for parameter PlanCutoverLayer - Details : Invalid JSON for GPFeatureRecordSetLayer or GPRecordSet datatype
  • Error: Failed.

Could you please let me know if its also a limitation from Select Widget.

Thanks in advance.

0 Kudos
Vara_PrasadM_S
Frequent Contributor

Hi @Wei_Ying ,

Could you please help me in this regards. 

With Regards.

0 Kudos