I m getting an sqlcode of -311 while performing multi-row insert.The sql works for a single row but does not work for multiple rows.How to solve this?
Sql Code = -311
Collapse
X
-
Tags: None
-
What is the SQl that you are executing?
SQL0311N The length of string host variable number "<var-number>" is
negative or greater than the maximum.
Explanation:
When evaluated, the length specification for the string host variable,
whose entry in the SQLDA is indicated by <var-number> (based at 1), was
negative or greater than the maximum defined for that host variable.
The statement cannot be processed.
User response:
Correct the program to ensure that the lengths of all string host
variables are not negative or that they are not greater than the maximum
allowed length.
sqlcode: -311
sqlstate: 22501
Comment