SQLQuery: Cannot use JSON_OBJECT with literals
Hello, I just noticed that the following query is not allowing when using cached queries.
The compiler will accuse the code about missing a closing quote.
Just so you know, if I use this query dynamically it works, so I guess it's related to the code linting.
Query T() As %SQLQuery [ SqlProc ] { SELECT TOP 3 JSON_OBJECT('lit':'Employee from','t':%TABLENAME,'name':Name,'num':SSN) FROM Sample.Employee }
The bold part is what is causing the error.
Version 2017.
And where error?
And version just 2017, is not enough. Is it 2017.1 or 2017.2?
Notice that if you put space after ':' then it compiles OK:
I got the same error, with %SQLQuery and embedded SQL (&sql), and in 2017.2 too.
Looks like some error, and you should say about it to the WRC.
While it works perfectly with %SQL.Statement, and through Management Portal
Or just from the documentation page, here.