Oracle データベースへの接続を含む NodeJS(v0.10.36) ファイルを実行しようとしています。
プロジェクトを実行しようとすると、以下のエラーが発生します。
M1318657:testOracle yogeshJC$ node app.js
module.js:340
throw err;
^
Error: Cannot find module '../build/Release/oracle_bindings'
at Function.Module._resolveFilename (module.js:338:15)
at Function.Module._load (module.js:280:25)
at Module.require (module.js:364:17)
at require (module.js:380:17)
at Object.<anonymous> (/Users/yogeshJC/testOracle/node_modules/oracle/lib/oracle.js:2:16)
at Module._compile (module.js:456:26)
at Object.Module._extensions..js (module.js:474:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:312:12)
at Module.require (module.js:364:17)
app.js には、Oracle データベースに接続するための簡単なスクリプトが含まれています。
ここの指示に従ってoracledbをインストールしました
オラクルのバージョン: 11.2
以下の環境が設定されています。
OCI_HOME
OCI_INC_DIR
OCI_VERSION
OCI_LIB_DIR
問題を解決するためのリードをいただければ幸いです。
編集 :
sudo npm install oracledb
M1318657:testOracle yogeshJC$ sudo npm install oracledb
Password:
npm WARN package.json appdynamics@4.1.10 No repository field.
npm WARN package.json express-namespace@0.1.1 No repository field.
|
> oracledb@1.9.3 install /Users/yogeshJC/testOracle/node_modules/oracledb
> node-gyp rebuild
CXX(target) Release/obj.target/oracledb/src/njs/src/njsOracle.o
CXX(target) Release/obj.target/oracledb/src/njs/src/njsPool.o
CXX(target) Release/obj.target/oracledb/src/njs/src/njsConnection.o
CXX(target) Release/obj.target/oracledb/src/njs/src/njsResultSet.o
CXX(target) Release/obj.target/oracledb/src/njs/src/njsMessages.o
CXX(target) Release/obj.target/oracledb/src/njs/src/njsIntLob.o
../src/njs/src/njsIntLob.cpp:1222:3: warning: cannot refer to a non-static member from the handler of a constructor function try block [-Wexceptions]
cleanup();
^
1 warning generated.
CXX(target) Release/obj.target/oracledb/src/dpi/src/dpiEnv.o
CXX(target) Release/obj.target/oracledb/src/dpi/src/dpiEnvImpl.o
../src/dpi/src/dpiEnvImpl.cpp:114:3: warning: cannot refer to a non-static member from the handler of a constructor function try block [-Wexceptions]
cleanup();
^
1 warning generated.
CXX(target) Release/obj.target/oracledb/src/dpi/src/dpiException.o
CXX(target) Release/obj.target/oracledb/src/dpi/src/dpiExceptionImpl.o
CXX(target) Release/obj.target/oracledb/src/dpi/src/dpiConnImpl.o
../src/dpi/src/dpiConnImpl.cpp:100:3: warning: cannot refer to a non-static member from the handler of a constructor function try block [-Wexceptions]
cleanup();
^
../src/dpi/src/dpiConnImpl.cpp:139:3: warning: cannot refer to a non-static member from the handler of a constructor function try block [-Wexceptions]
cleanup ();
^
2 warnings generated.
CXX(target) Release/obj.target/oracledb/src/dpi/src/dpiDateTimeArrayImpl.o
CXX(target) Release/obj.target/oracledb/src/dpi/src/dpiPoolImpl.o
../src/dpi/src/dpiPoolImpl.cpp:145:3: warning: cannot refer to a non-static member from the handler of a constructor function try block [-Wexceptions]
cleanup();
^
1 warning generated.
CXX(target) Release/obj.target/oracledb/src/dpi/src/dpiStmtImpl.o
../src/dpi/src/dpiStmtImpl.cpp:121:3: warning: cannot refer to a non-static member from the handler of a constructor function try block [-Wexceptions]
cleanup ();
^
1 warning generated.
CXX(target) Release/obj.target/oracledb/src/dpi/src/dpiUtils.o
CXX(target) Release/obj.target/oracledb/src/dpi/src/dpiLob.o
CXX(target) Release/obj.target/oracledb/src/dpi/src/dpiCommon.o
SOLINK_MODULE(target) Release/oracledb.node
SOLINK_MODULE(target) Release/oracledb.node: Finished
oracledb@1.9.3 node_modules/oracledb
└── nan@2.3.4