Select to view content in your preferred language

Can a point-in-polygon query be combined with a URL parameter fed value?

457
2
Jump to solution
09-07-2022 08:56 AM
SFM_TravisBott
Frequent Contributor

My question: does having a JSON function in the calculation column preclude using a URL parameter to feed the same field?

I have a survey where a point is sometimes but not always required for data entry. For the times when a user drops a point I would like to use a point in polygon query to pull in attributes, e.g. pulldata("@json",${myJSON},"attributes.County"). This work great. 

However, as the survey is often accessed through a dashboard and launched in relation to an underlying jurisdiction dataset I would like to be able to feed the the same values through the URL parameter. Is this possible in the same survey? In early tests I could not get my URL parameters to work unless I deleted the pulldata calculation. 

0 Kudos
1 Solution

Accepted Solutions
DougBrowning
MVP Esteemed Contributor

Trick with these is to push the URL param into a different field.  Then have a 3rd field with an if(URL value is blank, use pulldata, else use URL value).  You can set the bind esri to null so it just stores the final result.  

hope that helps

View solution in original post

0 Kudos
2 Replies
DougBrowning
MVP Esteemed Contributor

Trick with these is to push the URL param into a different field.  Then have a 3rd field with an if(URL value is blank, use pulldata, else use URL value).  You can set the bind esri to null so it just stores the final result.  

hope that helps

0 Kudos
SFM_TravisBott
Frequent Contributor

Thanks, this worked great. I combined this with info you provided from another post linking if statements together. Made for a long and complicated calculation but I have the functionality I want ('if launched from URL parameter then fill the values, else if dropping a point then use the value from a json query, else leave blank and autofill from a csv).