Select to view content in your preferred language

Let me explicitly state something is NOT a query layer parameter

383
0
12-13-2024 10:06 AM
Status: Open
Labels (1)
jcarlson
MVP Esteemed Contributor

Query layers are great. PostgreSQL + PostGIS is great. I use them all the time.

PostgreSQL has a shorthand of using a double colon to cast data types.

CAST('100' AS INTEGER)

is the same as

'100'::INTEGER

So what's the problem? Whenever Pro sees "::", it thinks I'm using a query layer parameter. Instead of letting me cast a value as an integer, it just looks for a parameter named "INTEGER" and throws an error when I don't supply one.

The query will still validate and load, but the features won't draw on the map.

I know, I could just rewrite my things to use CAST instead, and will likely do so for the time being. It just seems a bit absurd for Esri to use an existing SQL convention as their "flag" for something else.

I'm not saying take them our or change the "::" to something else. Just give me a way to tell the program that "no, this is *not* a parameter, just read it as the text I wrote"!