-
Notifications
You must be signed in to change notification settings - Fork 53
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
Add a mark to finish query #11
Comments
Good question, a simpler solution would be strip all the comments when parsing the file, so you don't have to write specific annotations. |
Yes, this is a good idea. |
emmmm, is there a risk of sql-injection?
|
i have many sql in dot.sql, i want using comment to splite these lines, but i can't using |
comment must start as
|
refer to my current |
Let's say we use comments to group sql queries
Example
In current implementation
--- REPORTS---
comment belongs toLevelUpdate
query. Problem is whenLevelUpdate
is not complete and we update the query on the program side. Let's imagine t hat we have the following:and in the application:
This will fail:
ERROR: syntax error at end of input (SQLSTATE 42601)
- becausequeries.LevelUpdate
is finishing with a comment. I know that we can bind here thesqlx
solution, however this is just a simple example.We need a phrase to end the query, eg:
--end
The text was updated successfully, but these errors were encountered: