I have timestamp (05-DEC-15 03.48.57.061000000 PM
) in one of our tables. I want to compare this timestamp to retrieve data. I have written following query
select * from ACTIVATIONRECORDS
WHERE ACTIVATIONDATE =
TO_DATE('04-12-15 03.48.57.052000000 PM','DD-MM-YY HH.MI.SS.SSSSS PM');
But its failing with following error
ORA-01861: literal does not match format string
01861. 00000 - "literal does not match format string"
*Cause: Literals in the input must be the same length as literals in
the format string (with the exception of leading whitespace). If the
"FX" modifier has been toggled on, the literal must match exactly,
with no extra whitespace.
*Action: Correct the format string to match the literal.