Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All,
My data base is returning time in this format
can anyone help me to convert this into day ,hours(24hrs format),min parts as individual fields.
Hi,
greetings for the day to all!!
can anyone help me on this issue?
Thanks
Aniruddhya
Hi Aniruddhya,
I'm using the Date() function and templates from memory but it should be very similar to this:
Date(Date#(Field, 'DD-MMM-YY hh.mm.ss.fffffffff TT')) AS Date
Miguel
Hi,
Please check the below code,
DateTbl:
Load * Inline [
TempDate
01-Oct-16 01.00.13.000000440PM
];
NoConcatenate
DateFormatTbl:
LOAD Date(Date#('01-Oct-16 01.00.13.000000440 PM', 'DD-MMM-YY hh.mm.ss.fffffffff TT'),'M/D/YYYY h:mm:ss[.fff]') as TempDate
Resident DateTbl;
DROP Table DateTbl;
Calendar:
LOAD Date(TempDate) as SampleDate,
Month(TempDate) as SampleMonth,
Year(TempDate) as SampleYear,
Hour(TempDate) as SampleHour,
Minute(TempDate) as SampleMinute
Resident DateFormatTbl;
DROP Table DateFormatTbl;
Regards,
Leni Balakrishnan
Thanks a lot it worked!!
Hi leni,
Thanks for your detailed reply.the format you mentioned also worked for me..:)