Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

date format

Hi,

i want year,month,week and hrs,second from following date format....

is it possible to get all this from following date format.

ex...

2013.01.08 01:15:20

3 Replies
Gysbert_Wassenaar

year(timestamp#('2013.01.08 01:15:20',YYYY.DD.MM hh:mm:ss))

month(timestamp#('2013.01.08 01:15:20',YYYY.DD.MM hh:mm:ss))

week(timestamp#('2013.01.08 01:15:20',YYYY.DD.MM hh:mm:ss))

hour(timestamp#('2013.01.08 01:15:20',YYYY.DD.MM hh:mm:ss))

minute(timestamp#('2013.01.08 01:15:20',YYYY.DD.MM hh:mm:ss))

second(timestamp#('2013.01.08 01:15:20',YYYY.DD.MM hh:mm:ss))

If your timestamp is already a numeric timestamp and not a string then you don't need the timestamp# function, but can use the year, month, ...etc functions directly on the field: year(MyTimeStampField) etc


talk is cheap, supply exceeds demand
Not applicable
Author

Hi,

I am using

year(('Date_Time')YYYY.DD.MM hh:mm:ss) as year

but i am getting error on above underline portion....

Not applicable
Author

hi,

i solved problem