-
Notifications
You must be signed in to change notification settings - Fork 501
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
proposal: driver facility to break up query batches #186
Comments
@kardianos note that the syntax of the go statement is GO [count] Please see https://docs.microsoft.com/en-us/sql/t-sql/language-elements/sql-server-utilities-statements-go |
It is indeed. In that package I took a shortcut because I never personally use the [count]. I will do a more correct parsing before submitting to this repo. |
I cannot find the syntax for the isql/osql/sqlcmd scripts. I know the go and \ syntax. Backslash is documented here https://docs.microsoft.com/en-us/sql/t-sql/language-elements/sql-server-utilities-statements-backslash |
@dimdin I've fuzzed the associated PR, it should be good to go. Let me know/merge if you think it is good to go. |
SQL Server often breaks up queries with a keyword, often "GO".
Offer a parser package that parses a query and returns multiple query texts to run. This would not normally be done on a query, the user would need to separate them out by calling a separate API. I have an implementation I could donate here:
https://bitbucket.org/kardianos/rdb/src/9016e187c250331d1c1c35444a69f27b87bdb5e8/ms/batch/?at=default
The text was updated successfully, but these errors were encountered: