## Where communities thrive

• Join over 1.5M+ people
• Join over 100K+ communities
• Free without limits
##### Activity
• Jan 31 2019 14:34
willmorgan commented on 889cbf1
• Jan 31 2019 13:15
gsamal commented on 889cbf1
• Jan 31 2019 13:10
dhensby closed #797
• Jan 31 2019 13:10
dhensby commented #797
• Jan 31 2019 13:07
dhensby closed #795
• Jan 31 2019 13:07
dhensby commented #795
• Jan 31 2019 12:58
gsamal commented #789
• Jan 31 2019 11:50
cesco69 opened #797
• Jan 31 2019 10:22

dhensby on master

Update changelog for v5 Merge pull request #796 from dh… (compare)

• Jan 31 2019 10:22
dhensby closed #796
• Jan 31 2019 09:53
dhensby commented #789
• Jan 31 2019 09:52
dhensby commented #778
• Jan 31 2019 09:51
dhensby review_requested #796
• Jan 31 2019 09:51
dhensby opened #796
• Jan 31 2019 06:45
suckerp commented #795
• Jan 31 2019 02:58
liumorgan starred tediousjs/node-mssql
• Jan 31 2019 02:15
zhoukk starred tediousjs/node-mssql
• Jan 30 2019 22:22
vjpr edited #795
• Jan 30 2019 22:22
vjpr edited #795
• Jan 30 2019 22:22
vjpr opened #795
romykundal
I need to resolve my error
i have error as below :
ConnectionError: Unknown driver [object Object]!
at new Connection (C:\Users\Brst-Pc102\Documents\2NetU\nodeProject\netu\node_modules\mssql\lib\main.js:197:15)
at Object.module.exports.selectDataPackages (C:\Users\Brst-Pc102\Documents\2NetU\nodeProject\netu\server\models.js:118:18)
at C:\Users\Brst-Pc102\Documents\2NetU\nodeProject\netu\server\app.js:103:11
at Layer.handle [as handle_request] (C:\Users\Brst-Pc102\Documents\2NetU\nodeProject\netu\node_modules\express\lib\router\layer.js:95:5)
at next (C:\Users\Brst-Pc102\Documents\2NetU\nodeProject\netu\node_modules\express\lib\router\route.js:131:13)
at Route.dispatch (C:\Users\Brst-Pc102\Documents\2NetU\nodeProject\netu\node_modules\express\lib\router\route.js:112:3)
at Layer.handle [as handle_request] (C:\Users\Brst-Pc102\Documents\2NetU\nodeProject\netu\node_modules\express\lib\router\layer.js:95:5)
at C:\Users\Brst-Pc102\Documents\2NetU\nodeProject\netu\node_modules\express\lib\router\index.js:277:22
at Function.process_params (C:\Users\Brst-Pc102\Documents\2NetU\nodeProject\netu\node_modules\express\lib\router\index.js:330:12)
at next (C:\Users\Brst-Pc102\Documents\2NetU\nodeProject\netu\node_modules\express\lib\router\index.js:271:10)
Please provide me any resolution for this
resolve error
Anybody can help in this case?
Aris Kemper
@ariskemper
Hi
is there a way to set Language for login? It uses all the time us_english instead language setled on db server for the login user.
Milan Willems
@Milanw2
Hello! I'm getting an error in my MEAN stack application. "req.query is not a function". Any ideas? Thanks in advance!
Aris Kemper
@ariskemper
How do you use node-mssql, if you have mean stack app?
Milan Willems
@Milanw2
Node is running in the background, so isn't it possible to add mssql?
Aris Kemper
@ariskemper
Mean stack means you are using mongodb
Milan Willems
@Milanw2
I know, but can't I just use mssql to acces my sql server?
The thing is that I'm trying to build an Angular 2 web application and I need a way to get data from an Microsoft SQL server. I thought I could use node in the background to access this data?
I'm using this tutorial to build the starting application https://scotch.io/tutorials/mean-app-with-angular-2-and-the-angular-cli
Or do you know a better way to build my application?
Aris Kemper
@ariskemper
Offcourse you could use node-mssql
Check node mssql documentation on how to connect to mssql server
Milan Willems
@Milanw2
Yeah I got that working in a Node console application
But now I'm getting the error: req.query is not a function
Aris Kemper
@ariskemper
This is something with express and sending params to endpoint.
Milan Willems
@Milanw2
Any idea how I can fix this?
Aris Kemper
@ariskemper
I cant give you direct answer
Milan Willems
@Milanw2
Do you know a tutorial I can follow for a new project? Not necessarily a MEAN stack application
I just need to build an Angular 2 app with data from an SQL server
Milan Willems
@Milanw2
router.get('/posts', (req, res) => {
conn.connect(function (err) {
if (err) {
console.log("connection error -->" +err);
return;
}
req.querySELECT TOP (10) u.* FROM [Alg].[User] AS u;, function (err, recordset) {
if (err) {
console.log("query error -->" + err);
return;
}
else {
console.log(recordset);
res.send(recordset);
}
conn.close();
};
});
});
this is the code which gives the error
any help?
crdil
@crdil
Hello. I'm trying to read queries from a file and run them, but I can't make it work. I'm reading the file with fs.readFile and utf8 into a buffer which I then try to run as query. Is this the wrong approach?
Sotirios Mantziaris
@mantzas
hi, i am trying to use the package inside a aws lambda. is there any walk through/example out there that shows how to get a connection, begin a transaction, commit/rollback transaction, close connection. etc. It seems that my code finds the connection open on subsequent calls to the lambda.
Ali Shaikh
@AliShaikh94
Hi, anyone here?
Selçuk GÜRAL
@selcukgural
hi, how can run query synchronous?
David Gasperoni
Is there a way to increase the connection pool?
dmanhaus
@dmanhaus
Basic question: I'm trying to refactor some code I wrote to use connection pooling asynchronously. The examples posted on the github repo are not sufficient for me to understand how to write the solution correctly. Are there any fully-featured example solutions in anyone's git repo I can look at? My app wants to open a sql connection pool and export execute methods for other modules to call upon. I am using koa wrapped around mssql to stand up an API backed by a sql database.
dmanhaus
@dmanhaus
Never mind. Worked it out.
snenp
@snenp
Hi,
anyone, knows if is it possible to mantain 2 connections to 2 different servers?
Wellington Rodriguez
@wrod7
anyone using mssql 2017 on linux? is it ready for production?
Paul
@karooga
dmanhaus: I have a similar issue, what was the work around that you used?
Paul
@karooga
Hi, anyone using mysql with promises, as per the documentation: https://www.npmjs.com/package/mssql
The examples don't seem to be correct from what I can see.
Javier Castro
@jacargentina
Hi! any chance to get a new release using tedious@next ?
Wellington Rodriguez
@wrod7
@jacargentina what is tedious next? node-mssql is using 2.0 I believe
Wellington Rodriguez
@wrod7
hello im trying to setup a single db file that exports a connection pool to it can be used throughout my entire web application (im new to mssql so please tell me if this isn't the right thing to do) any reason why this wouldn't work:
David Gasperoni
connectionPool = new mssql.ConnectionPool({user, password, server, database});
and keep around the returned Promise from connectionPool.connect()
@wrod7 i think it depends on the version you're using… connect() returns a promise, so you need to chain a .then() to wait for the connection