While executing some queries using DB2 JDBC Type 4 Universal driver in java application, the following error is thrown
Code:
DB2 SQL error: SQLCODE: -104, SQLSTATE: 42601, SQLERRMC: ;;) + CURRENT TIMEZONE;END-OF-STATEMENT
The sql query is as below
Code:
delete from ice.right_column where rc_id = 'pm025491' and rc_launch_date = TIMESTAMP('2006-11-23-05.01.00') + CURRENT TIMEZONE;
The query was working fine with DB2 CLI Native driver, but on porting the application to JDBC Type 4 Universal driver, the above error is coming up.
The error is because of trailing semicolon, removing which removes the error.
But our application is such that modifying queries will involve a lengthy process (i.e the queries are generated by some other application),
is there a way of configuring the Type 4 driver (specifying/despecifying statement delimiter...etc) so that it stops complaining !!!.
And if someone can throw some light(i.e any DB2 developers ??) as to the core reason why Type 4 driver is complaining, bearing in mind that the CLI driver has no issues with it.
Thanks in advance !!.