Hello all, I'm new at SQL so I have been struggling with To_Date function!
Thats the error:
Date format in the database is like this:
Any ideias?
thanks in advance!
Solved! Go to Solution.
Change the format string in the To_Date function so that it matches the input string.
To_Date('2018-01-01 00:00:00', 'yyyy-mm-dd HH24:MI:SS')
Also note that in Oracle, HH24 is the format string for represents hours from 0-23. If you use HH, you also need the AM/PM specifier. Since this isn't in you data, use HH24
Dan
Hey, Dani thanks for the reply!
I got the same error, am I doing something wrong?
Because of the number of fields that your selecting, the actual error message that your getting isn't displayed in the dialog box. Create a simple query selecting only one field from and try that. The ultimate goal is to the see the text of the error message.
Dan
The error was because I was trying to convert the date with no reason, with "to_date".
My goal was to just FILTER the dates, so I just used >= '2018-01-01".
thanks for the help