Select to view content in your preferred language

Calculated URL converts question mark to colon

528
5
Jump to solution
05-11-2023 07:32 AM
BryanBurns
New Contributor II

I'm trying to construct a URL to launch the Survey123 app from a field within my table and using calculate to do so. The problem I'm running into is that the SQL calculate tool will convert any question marks (?) that I have in my URL to a colon (:). For example, I input the following string:

'https://survey123.arcgis.app?itemID=123456xxx12345xxx12345xxxx'  

and after running the calculate, it converts to 

https://survey123.arcgis.app:itemID=123456xxx12345xxx12345xxxx  

Anyone know of a way around this? I've tried using double question marks (??) but it converts to @.  I've tried using question mark in brackets [?] but it converts to [:] 

0 Kudos
1 Solution

Accepted Solutions
Clubdebambos
Occasional Contributor III

Thats a shame. We use url construction in the popup rather than an attribute in the table and it works successfully. Two links, one for desktop and one for mobile app.

Desktop: https://survey123.arcgis.com/share/b5XXX60XXb0fXXX08c82fdf30XXXXXXX 

Mobile: arcgis-survey123://?itemID=b5XXX60XXb0fXXX08c82fdf30XXXXXXX 

Clubdebambos_0-1683825485523.png

Write text and create as link.

Clubdebambos_1-1683825554672.png

 

 

~ learn.finaldraftmapping.com

View solution in original post

0 Kudos
5 Replies
Clubdebambos
Occasional Contributor III

Hi @BryanBurns 

You could try URL encoding and instead of ? use %3F

~ learn.finaldraftmapping.com
0 Kudos
BryanBurns
New Contributor II

So I gave that a try and the encoding comes through as text - ie: it doesn't recognize the encode. So my result was: https://survey123.arcgis.app%3FitemID=123456xxx12345xxx12345xxxx

0 Kudos
Clubdebambos
Occasional Contributor III

Thats a shame. We use url construction in the popup rather than an attribute in the table and it works successfully. Two links, one for desktop and one for mobile app.

Desktop: https://survey123.arcgis.com/share/b5XXX60XXb0fXXX08c82fdf30XXXXXXX 

Mobile: arcgis-survey123://?itemID=b5XXX60XXb0fXXX08c82fdf30XXXXXXX 

Clubdebambos_0-1683825485523.png

Write text and create as link.

Clubdebambos_1-1683825554672.png

 

 

~ learn.finaldraftmapping.com
0 Kudos
BryanBurns
New Contributor II

@Clubdebambos  - you da man! I was going about it the hard way but your screen shot pointed me in the right direction. Also worth noting, is that the "Custom Attribute Display" option doesn't appear to be in the new Map Viewer UI, only in Map Viewer Classic (or maybe it is and I just overlooked it.. ?) 

Clubdebambos
Occasional Contributor III

Great stuff. We continue to use the Map Viewer Classic until Map Viewer gets more mature and inline with Classic and beyond.  

~ learn.finaldraftmapping.com
0 Kudos