You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Redshift dialect: [...] after an expression is a subscript, not a quoted identifier #2960
RedshiftSqlDialect accepts [ as a delimited identifier quote. In Redshift, brackets after an expression index into a SUPER value, and identifiers are quoted only with double quotes.
select a[pg_backend_pid() - pg_backend_pid()] from (select json_parse('[1,2]') as a)
sqlparser 0.64.0: Word { value: "pg_backend_pid() - pg_backend_pid()", quote_style: Some('[') }; parses as SELECT a AS [pg_backend_pid() - pg_backend_pid()] FROM ....
Redshift: returns a = 1, i.e. a[0], so the bracket contents ran as an expression.
Activity