Question

I am encoutering this error while inserting timestamp value into the sybase any where database. Any help
com.sybase.jdbc3.jdbc.SybSQLException: ASA Error -157: Cannot convert 2006 05 29 04:00 to a timestamp ; nested exception is: BINDING.JCA-11811 Stored procedure invocation error. Error while trying to prepare and execute

Was it helpful?

Solution

The date format to be passed is kind of different it expects the date in the following format

DD-MMM-YYYY HH:MM:SS

Where DD is date in numeric eg: 09 Where MMM is month in abbrev form eg:JUN for july where YYYY is year in 4 digits eg: 2013

hh:mm:ss is the time stamp without timezone

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top