I have the following in my SQL where article. This works with an Oracle database. The sc_dt field sc_dt defined in db as a date field.
sc_dt = TO_DATE('2011-11-03 00:00:00.0', 'YYYY-MM-DD')
throws the following error "date format picture ends before converting entire input string"
When I try to explain fractional seconds ( .0 in this case) with the following, I get the following error.
sc_dt = TO_DATE('2011-11-03 00:00:00.0', 'YYYY-MM-DD HH24:MI:SS.FF')
produces the following error "date format not recognized"
I really assume I need .FF to account for .0 in the from from line. I also tried .FF1 , .FF2 , ..., .FF9 with the same results (at this moment I grab onto a straw).
As far as I can see, the sc_dt field always contains the filled month / day / year (and not the hour / minute / second part).
I am debugging a java program that executes the above SQL as a prepared statement with a value of 2011-11-03 00:00:00.0 .
How can I get around this?
acedanger
source share