-
Notifications
You must be signed in to change notification settings - Fork 26
Description
Snowflake supports a column type called variant
, which supports JSON and other JSON-like semi-structured data. One syntax to be able to index a variant column is by using the colon character, what the Snowflake documentation calls dot notation, per docs here.
As far as I can tell, there is no current support for this notation. If, in a where
, I try to specify a field as this dot notation, e.g. foo:bar
, then the query compiler mistakenly tries to quote this as "foo:bar"
, when the correct quotation is supposed to be "foo":"bar"
. This results in an error.
I've found that Knex supports a custom wrapIdentifier
, per docs here. This is definitely one possible work-around. As far as I can tell, knex-snowflake-dialect already supplies its own wrapIdentifier
implementation, but it doesn't support dot notation. Hence, the above issue.
I'm working on seeing if I can get a work-around to work locally. Perhaps, however, this should be integrated into the library.
Let me know your thoughts. Thanks.