-
Notifications
You must be signed in to change notification settings - Fork 777
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
sqlc panics on v1.21.0 in sqlite.getTables
#2729
Comments
inner join
Tracked down which query was the problem and have updated ☝️ |
inner join
sqlite.getTables
In my code, I'm seeing this line panic because |
I've raised #2730 for this, but not sure it's the most optimal solution - I assume we should add a regression test for this, happy to do so, or if you want to proceed with fixing it with a fresh PR! |
close sqlc-dev#2729 ANTLR's API has difficulty handling the case where there is no join_constraint corresponding to join_operator in join_clause, so an empty join_constraint is accepted. It is defined as such in the sqlite documentation. https://www.sqlite.org/syntax/join-clause.html https://www.sqlite.org/syntax/join-constraint.html
This seems to be caused by the inability to properly handle queries that do not have an ON corresponding to a JOIN. |
close #2729 ANTLR's API has difficulty handling the case where there is no join_constraint corresponding to join_operator in join_clause, so an empty join_constraint is accepted. It is defined as such in the sqlite documentation. https://www.sqlite.org/syntax/join-clause.html https://www.sqlite.org/syntax/join-constraint.html
Version
1.21.0
What happened?
Panic received when trying to generate code
Relevant log output
Database schema
SQL queries
Configuration
No response
Playground URL
https://play.sqlc.dev/p/e3437505ebfba3f93003f631460d29cedd52b246eabbcb030281e3172eb36097
What operating system are you using?
No response
What database engines are you using?
SQLite
What type of code are you generating?
Go
The text was updated successfully, but these errors were encountered: