Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
alec1982
Specialist II
Specialist II

Date Field

Hi,

I have a date field that looks like:

[End Date]

1-May-2012

3-June-2008

5-April-2007

Tried to format it so i can pull the year by itself but didn't work. Year([End Date])

I tried to do :

Date#([End Date]) as Date,

Date( Date#( [End Date], 'MM/DD/YYYY' ) ) as Date,

Both options didn't work. Any idea?

Thxs for your help,

Alec

1 Solution

Accepted Solutions
MayilVahanan

Hi

Please check the attached file

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.

View solution in original post

3 Replies
MayilVahanan

Hi

Please check the attached file

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.
diegofcaivano
Partner - Creator
Partner - Creator

Hi Alec,

The second parameter of the DATE#() function is the mask used to interpret the field value. In your case, it would be:

DATE(DATE#([End Date], 'D-MMMM-YYYY')) AS [End Date]

Regards.

alec1982
Specialist II
Specialist II
Author

Thxs guys!