Issue with a url query in SQL Calc Field

587
1
09-13-2019 11:41 AM
RyanClose
New Contributor III

Does anyone else have an issue in AGOL calculating a filed to update a url link with a "?" in it? Every time I tried paste a url with a query

(ex: https://<front of url>..../DistrictBallotView.aspx?DistrictKey=31...<end of url>....)

it changes the "?" to a ":"

(ex: https://<front of url>..../DistrictBallotView.aspx:DistrictKey=31...<end of url>....)

To be clear, I'd paste the url and it looks fine. I hit calculate and the result has the colon instead of the question mark.

This ONLY seems to happen in the SQL version of editing. I had to change settings on the feature class to be able to make the edit in Arcade and then change the setting back.

0 Kudos
1 Reply
LanceCole
MVP Regular Contributor

Ryan‌,

A "?" is a placeholder in a SQL statement depending where it is located in the statement.  If your URL is contained in quotes as part of the WHERE clause is this should be ok other wise the SQL will replace the ? with a value.  Depending upon the driver, using a double question mark "??" or wrapping the question mark in brackets "[?]" in the URL may escape the issue.  Can you provide a copy of the full SQL statement?

0 Kudos