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

please give node-sqlserver-v8 a try! #1

Open
TimelordUK opened this issue Sep 17, 2015 · 6 comments
Open

please give node-sqlserver-v8 a try! #1

TimelordUK opened this issue Sep 17, 2015 · 6 comments

Comments

@TimelordUK
Copy link
Owner

greetings. I hope you find some use in this module. I intend to add additional features which hopefully will be based on the community feedback. So please feel free to make suggestions for improvements or issues with the new stored procedure feature.

@meet-bhagdev
Copy link

This is great!! I am giving it a try and will let you know if I find something. This absolutely amazing though!!!!

@tysjiang
Copy link

Currently using it, works great!

@robokozo
Copy link

robokozo commented Oct 7, 2015

I've never connected to an SQL server from Node so this is all new to me. I haven't been able to get this implementation working.
Right now, I'm getting a message:

{ [Error: [Microsoft][SQL Server Native Client 11.0][SQL Server]Login failed for user USERNAME.] sqlstate: '28000', code: 18456 }

Any ideas?

@TimelordUK
Copy link
Owner Author

this error has come back from SQL server, so clearly you are at least communicating with the database. Are you using windows authentication or a database account? The connection has to be configured as below. If you use authentication, set the trusted flag true and the user and password are not therefore required. If the server requires a user and password, then the flag should be false and the credentials set. Is this a local database or an instance maintained by DBA's? How would you connect from Management Studio normally? The configuration below would be precisely inline with your normal access.

var driver = 'SQL Server Native Client 11.0';
var server = '<your_server>';
var user = '';
var pwd = '<password';
var database = 'AdventureWorks2012';
var useTrustedConnection = false;
var conn_str = "Driver={" + driver + "};Server=" + server + ";" + (useTrustedConnection == true ? "Trusted_Connection={Yes};" : "UID=" + user + ";PWD=" + pwd + ";") + "Database={" + database + "};";

@robokozo
Copy link

robokozo commented Oct 8, 2015

Thanks, TimelordUK. I was able to get it working eventually by using https://www.npmjs.com/package/mssql and renaming your package to stand in for the official MS package in the node_modules folder.

@paulbjensen
Copy link

I'm using this at work, thank you for making it.

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

No branches or pull requests

5 participants