Closed ciarand closed 1 year ago
Thanks for reporting, yes column specification might miss some corner cases. I am a bit short on time for the next weeks, but I can have a look.
As of now, the parser can only use indentifiers
there after this as
: https://github.com/DerekStride/tree-sitter-sql/blob/9ed90cc742a396423610d0523db0ea5751fa795e/grammar.js#L2206
Should be at least an _expression
Hello! This is a wonderful parser that I benefit from daily. Thanks for your hard work!
I noticed an issue when I was experimenting with generated columns in my SQLite schema. Here's a quick cut-down example:
https://sqlime.org/#deta:pak48dg2wu8z
The AST appears to break after the
AS
keyword:Since this is valid SQLite, it would be cool if it didn't break. I haven't checked other DB engines exhaustively, but it appears MySQL and Postgres offer similar constructs.
MySQL:
Postgres: