I just try to use the npm-sybase-nu to connect the Sybase server.
I have modified the connection information to connect my server in the example, and it works fine using the SQL query (by changing the SQL to "SELECT * FROM sysobjects" or others) in test.js.
But when I try to test with models in app.js, it return error in the connection statement as client is null.
TypeError: Cannot read property 'connect' of null
at CRUD (E:\node.js\node-sybase\app.js:5:32)
at Object. (E:\node.js\node-sybase\app.js:57:1)
at Module._compile (internal/modules/cjs/loader.js:956:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:973:10)
at Module.load (internal/modules/cjs/loader.js:812:32)
at Function.Module._load (internal/modules/cjs/loader.js:724:14)
at Function.Module.runMain (internal/modules/cjs/loader.js:1025:10)
at internal/main/run_main_module.js:17:11
I have defined the table t_wxuser according to the definition in wxuser.js, and also try to create a models for my own table, but both of them has error as client is null.
I try to debug the program, it was found that SyBase.DBPools.main is OK, but the client is always null.
May I know if I have missed some steps to initiate the client in SyBase.DBPools.main ?
Thanks a lot!
I just try to use the npm-sybase-nu to connect the Sybase server.
I have modified the connection information to connect my server in the example, and it works fine using the SQL query (by changing the SQL to "SELECT * FROM sysobjects" or others) in test.js.
But when I try to test with models in app.js, it return error in the connection statement as client is null.
I have defined the table t_wxuser according to the definition in wxuser.js, and also try to create a models for my own table, but both of them has error as client is null.
I try to debug the program, it was found that SyBase.DBPools.main is OK, but the client is always null.
May I know if I have missed some steps to initiate the client in SyBase.DBPools.main ? Thanks a lot!