i have a string containing comma separated strings in java.. which i m passing to a sql procedure being called in java ... here is example of java string:
String codeString = "'232/232','34fd/34//'";
code in sql db2 for i:
create procedure history (in id varchar (3), in code varchar (2000)) ...... ...... begin insert into table1 select date_from, date_to, code from table2 where table2.serial= id and table2.status not in (code); end
this sql procedure is inserting same string in table1.code but it is not excluding table2.status in in clause..
value being inserted in table1.code is '232/232','34fd/34//' (including all single quotes and commas)
I just wonder that when i insert code value in table1..it works fine even no issue with any single quote,comma.. but when i pas it to not in clause its creating problem