CLI0123E: SQL data type out of range. SQLSTATE=HY004
See original GitHub issueI am having a problem with calling stored procedure that has output parameters. This is the error:
Data is missing from [object Object]
{ Error: [IBM][CLI Driver] CLI0123E SQL data type out of range. SQLSTATE=HY004 at Error (native)
errors: [],
error: '[node-odbc] SQL_ERROR',
message: '[IBM][CLI Driver] CLI0123E SQL data type out of range. SQLSTATE=HY004',
state: 'HY004' }
My code:
ibmdb.open(driver+hostname+port+db+user+psw+protocol, function (err,conn) {
if (err) return console.log(err);
var query = "CaLL name.mySP(?,?,?,?,?,?,?,?,?,?,?)";
var param1 = {ParamType:"INPUT", DataType:1, Data:""};
var param2 = {ParamType:"INPUT", DataType:1, Data:""};
var param3 = {ParamType:"INPUT", DataType:1, Data:76145};
var param4 = {ParamType:"INPUT", DataType:1, Data:0};
var param5 = {ParamType:"INPUT", DataType:1, Data:0};
var param6 = {ParamType:"INPUT", DataType:1, Data:0};
var param7 = {ParamType:"INPUT", DataType:1, Data:""};
var param8 = {ParamType:"OUTPUT", DataType:1, Data:0};
var param9 = {ParamType:"OUTPUT", DataType:1, Data:0};
var param10 = {ParamType:"OUTPUT", DataType:1, Data:""};
var param11 = {ParamType:"OUTPUT", DataType:1, Data:0};
conn.query(query, [param1,param2,param3,param4,param5,param6,param7,param8,param9,param10,param11], function (err, data) {
if (err) console.log(err);
else console.log(data);
conn.close(function () { console.log('>> closed'); });
});
});
I was able to call stored procedure that has only input params but am unable to call any procedure that also has output params.
Any idea?
Issue Analytics
- State:
- Created 7 years ago
- Comments:36 (19 by maintainers)
Top Results From Across the Web
Known Issue: DT159043 - IBM
[IBM][CLI Driver] CLI0123E SQL data type out of range. SQLSTATE=HY004 SQL2977I Because of the previous error, the ingest utility will
Read more >SQL data type out of range. SQLSTATE=HY004 - DSXchange
im doing a unduplicate match job , when i link the output of unduplicate match to db2 connector , then i got this...
Read more >Error Sqlstate HY004 Using DG4ODBC to Connect to Non ...
[IBM][CLI Driver] CLI0123E SQL data type out of range. SQLSTATE=HY004 {HY004,NativeErr = -99999} ORA-02063: preceding 2 lines from DB2_LINK.
Read more >CLI0123E: SQL data type out of range. SQLSTATE=HY004
I am having a problem with calling stored procedure that has output parameters. This is the error: Data is missing from [object Object] ......
Read more >Execution group abends while calling DB2 Stored Procedure
SQLState = HY004 Native = 0x7f578f6a9c9c -> -99999. Message Text = [[IBM][CLI Driver] CLI0123E SQL data type out of range. SQLSTATE=HY004]
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@ljerka We have released the code changes for windows too. Please install ibm_db@1.0.2 and verify it. Thanks.
@ljerka Thank you for the explanation. We are looking into this and will come back with solution. 😃