Is there a way to defermine that column is a JSON_OBJECT

Primary tabs

I got a resultset, and some columns might be a JSON_OBJECT. Is there a way (based on metadata) to determine that the column was formed from JSON_OBJECT function?

set rs = ##class(%SQL.Statement).%ExecDirect(,"SELECT 1 colA, JSON_OBJECT('id':1) col2")
do rs.%Display()

I do not want to try parsing json.

Replies

I didn't meet that.

Basically it's %String or a %Stream based on size.
I'd suggest having a private data type.
This allows you also to have all tricky LogicalToODBC, .... under control. (and no MAXLEN for %String)
And mapping it to %ALL or naming it %ZstringJSON or similar makes it public and update-restistant 

Got you! 
Something  like $isJSON()  ?  like $isobject() or $listvalid()

select *,
case when is JSON then else end aa,
case when is JSON then else end bb,
case when is JSON then else end cc

from (SELECT aJSON_OBJECT('id':1) b'{"id":1}' c)