微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

在Windows平台上从Node.js连接DB2

我正在使用一些jdbc代码将DB2镜像到本地MysqL-db。 我想直接从Node.js应用程序连接DB2,而无需查询镜像。 我在Windows上运行,我不能更改为Linux。 看起来,使用Node.js的DB2上的工作还是非常less的,或者使用node-odbc(unixODBC绑定节点)。

我发现这个项目https://github.com/herzi/db2.js ,它为Node提供DB2绑定,但是当安装失败时,我无法安装它。 该软件包需要Node-gyp(已成功安装)和.NET框架SDK。 我把vcbuild.exe放到我的PATH中。 在这些msbuild.exe抱怨丢失的头文件sqlcli1.h,sqlsystm.h,sqlca.h),我发现是PRO * C的一部分。

我从这里获取了上面的头文件: http : //files.edin.dk/PHP/win32/dev/PHP_build/include/db2/ ,并将它们放到我的Node的src /目录中。 现在编译器显示多个错误

使用Windows从Node.js应用程序连接DB2时,是否还有其他select,而不是尝试使上述模块正常工作?

连接到IBM AS / 400 DB2数据库

pyodbc在我的机器上非常慢,但不在其他机器上

db2 linux控制台客户端

文件执行但符号链接

如何find一个string中的子string(或如何grep一个variables)?

任何人都可以帮助我在这里? 什么是安装上述模块的步骤?

谢谢!

显示错误

C:Program FilesMicrosoft SDKsWindowsv7.0Aincludesqlext.h(30): error C2146 : Syntax error : missing ';' before identifier 'sqlSTATE' [C:ISnodenode_modulesdb2builddb2.vcxproj] C:Program FilesMicrosoft SDKsWindowsv7.0Aincludesqlext.h(30): error C2146: Syntax error : missing ';' before identifier 'sqlSTATE' [C:ISnodenode_modulesdb2builddb2.vcxproj] C:Program FilesMicrosoft SDKsWindowsv7.0Aincludesqlext.h(30): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int [C:ISnodenode_modulesdb2builddb2.vcxproj] C:Program FilesMicrosoft SDKsWindowsv7.0Aincludesqlext.h(30): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int [C:ISnodenode_modulesdb2builddb2.vcxproj] C:Program FilesMicrosoft SDKsWindowsv7.0Aincludesqlext.h(30): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int [C:ISnodenode_modulesdb2builddb2.vcxproj] C:Program FilesMicrosoft SDKsWindowsv7.0Aincludesqlext.h(30): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int [C:ISnodenode_modulesdb2builddb2.vcxproj] C:Documents and Settingstpaleniu.node-gyp.8.12srcsqlcli1.h(1501): error C2371: 'sqlTCHAR' : redeFinition; different basic types [C:ISnodenode_modulesdb2builddb2.vcxproj] C:Program FilesMicrosoft SDKsWindowsv7.0Aincludesqlext.h(30) : see declaration of 'sqlTCHAR' ..srcconnection.cc(77): error C3861: 'snprintf': identifier not found [C:ISnodenode_modulesdb2builddb2.vcxproj]..srcconnection.cc(80): error C3861: 'snprintf': identifier not found [C:ISnodenode_modulesdb2builddb2.vcxproj] ..srcconnection.cc(111): error C3861: 'bzero': identifier not found [C:ISnodenode_modulesdb2builddb2.vcxproj] ..srcconnection.cc(208): error C3861: 'bzero': identifier not found [C:ISnodenode_modulesdb2builddb2.vcxproj] ..srcconnection.cc(547): error C2057: expected constant expression [C:ISnodenode_modulesdb2builddb2.vcxproj] ..srcconnection.cc(547): error C2466: cannot allocate an array of constant size 0 [C:ISnodenode_modulesdb2builddb2.vcxproj] ..srcconnection.cc(547): error C2133: 'argv' : unkNown size [C:ISnodenode_modulesdb2builddb2.vcxproj]

IBM CLI驱动程序 – 无效的参数值

成功安装DB2后,“第一步”快捷方式缺失

PHP / Linux到AS / 400-db2

警告:db2_fetch_assoc():提取失败

将进程的生命绑定到启动它的shell

目前node-odbc确实只适用于unixODBC。 但是Daniel Verweire目前正在支持Windows上的node-odbc 。 我想你需要等一会儿。

Praveen将尽快在这里发布信息

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 [email protected] 举报,一经查实,本站将立刻删除。

相关推荐