Skip to content
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

Let user can set node-mysql options #929

Merged
merged 2 commits into from Sep 27, 2013
Merged

Let user can set node-mysql options #929

merged 2 commits into from Sep 27, 2013

Conversation

poying
Copy link
Contributor

@poying poying commented Sep 23, 2013

It seems difficult for user to set node-mysql options before, Like supportBigNumbers and bigNumberStrings, I edit some code to improve the problem.

var sequelize = new Sequelize('database', 'username', 'password', {
  nodeMysql: {
    supportBigNumbers: true,
    bigNumberStrings: true
  }
});

@durango
Copy link
Member

durango commented Sep 23, 2013

Not a fan of the naming convention for "nodeMysql" would much prefer "connectionOptions" or "connectionParams" etc. (this way things aren't dialect specific). Also, a test would be cool :)

If you don't feel like doing it let me know I planned on doing this in #362 :P

@sdepold
Copy link
Member

sdepold commented Sep 24, 2013

Hmm. Are there any plans about using this stuff for other dialects as well? I wonder if "support" would be a better name for the config ^^.

@durango
Copy link
Member

durango commented Sep 24, 2013

@sdepold my thoughts exactly :)

@sdepold
Copy link
Member

sdepold commented Sep 24, 2013

👍

@prasad83
Copy link

using dialectOptions instead of nodeMysql seem to be doing the trick

javascript
var sequelize = new Sequelize('database', 'username', 'password', {
dialectOptions: {
supportBigNumbers: true,
bigNumberStrings: true
}
});

@mickhansen
Copy link
Contributor

@prasad83 dialectOptions was probably an abstract of this PR to allow one to do it for all dialects :)

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.

None yet

5 participants