Skip to content

fix: Only set cursor_close_on_commit if explicitly specified. - #653

Merged
arthurschreiber merged 2 commits into
masterfrom
arthur/fix-enableCursorCloseOnCommit
Nov 28, 2017
Merged

arthurschreiber merged 2 commits into
masterfrom
arthur/fix-enableCursorCloseOnCommit

Conversation

@arthurschreiber

Copy link
Copy Markdown
Collaborator

This is a follow up to #643 and fine-tunes the way the enableCursorCloseOnCommit connection option is handled.

Instead of only sending the cursor_close_on_commit option in the initial sql query payload if the enableCursorCloseOnCommit is explicitly set to true (without any option to disable cursor_close_on_commit), tedious now defaults to not sending cursor_close_on_commit. But if enableCursorCloseOnCommit is set to true or false explicitly, we either enable or disable this option in the initial sql query payload.

This way, users can decide whether they want to have the server's default cursor_close_on_commit value (by not specifying enableCursorCloseOnCommit), or explicitly set it to their required value.

Instead of generating one large string, we now build up an array of
option string parts and join these up to generate the final initial sql
query.
@Suraiya-Hameed

Copy link
Copy Markdown
Member

@arthurschreiber Thanks for taking care of this option :)

@arthurschreiber
arthurschreiber merged commit 46cf72d into master Nov 28, 2017
@arthurschreiber

Copy link
Copy Markdown
Collaborator Author

@v-suhame published a new version of tedious ([email protected]) that contains this fix. I also tagged it as latest, so all users should be able to connect to Azure SQL Data Warehouse now. Thank you so much! ❤️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants