Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi there,
I have a date with this format: Apr 13 2012 1:07PM and i want to convert it into 13/4/2012.
Any help?!
Thank you.
Try replacing the double spaces with single spaces:
date(floor(timestamp#(replace(DATEFIELD,' ',' '),'MMM DD YYYY h:mmTT')),'DD/M/YYYY') as NEWDATEFIELD
date(floor(timestamp#(DATEFIELD,'MMM DD YYYY h:mmTT')),'DD/M/YYYY') as NEWDATEFIELD
Thank you for your answer!
The problem remailns unfortunately in most of the records even though some have been transformed the way i wanted to.
For example: Feb 6 2012 9:26AM has been successfuly changed
But Feb 6 2012 11:38AM has not.
you change format hh:mmTT as expression in johannes sunden
hope this will helps you
Try replacing the double spaces with single spaces:
date(floor(timestamp#(replace(DATEFIELD,' ',' '),'MMM DD YYYY h:mmTT')),'DD/M/YYYY') as NEWDATEFIELD
Thank you all! I fixed it!
Haha, and I paid such attention to get the double spaces in there to match the date format you posted in the original post..
Glad you got it up and running mate!