2 ms·
I believe there is a grammar for SQL, but it probably doesn't support a lot of the vendor-specific language extensions you might be using. You could end up writ
by nerdponx 3y ago
I believe there is a grammar for SQL, but it probably doesn't support a lot of the vendor-specific language extensions you might be using. You could end up writing your own grammar or heavily extending any grammar that already exists. There might already be libraries specific to parsing Oracle SQL into a syntax tree, at which point Tree Sitter isn't really adding value.
That said, the ability to query for things like "all SELECT statements where table 'xyz' is referenced in any table identifier" is very powerful.
- hifikuno 3y agoThat's a good idea, that would save me starting from scratch. We do use a fair bit of vendor-specific language, would be cool to make a good Oracle version and then commit back to the project.