Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Nodejs ODBC Connection on Windows

I have a project that would be perfect for Node.js, but it has to connect to a ODBC database and it has to run on windows. I see ODBC modules for nodejs on linux, but not windows. Does anyone have any suggestions on how to do this?

like image 852
Clint Avatar asked Nov 21 '12 08:11

Clint


1 Answers

The node-odbc sais it is unixODBC for Linux, but it works in Windows too, I am using it here. It just does not include the binaries, so you need to install windows-build-tools and node-gyp before installing node-odbc, in order to build the binaries.

npm i -g windows-build-tools
npm i -g node-gyp
npm i odbc
like image 126
Prox Avatar answered Sep 28 '22 02:09

Prox