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

Announcements
Want to see what's currently in public preview? We've pulled it all together in one place. Check it out here
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Date format

hi,

Am having a tab seperated file. Which has column named dated of timestamp format.

In qlik view i want month year and start week out of that column, the code am using is given below

  

Date(dated,'YYYY-MM-DD') as EntryDate,
Year(dated) as Year,
Date(MonthStart(dated),'YYYY-MM') as MonthYear,
QuarterName(QuarterStart(dated)) as QuarterYear,
Date(WeekStart(dated),'YYYY-MM-DD') as StartWeek;

When i run with this queries its fetching zero rows.

Awaiting your response.

Regards,

Teja.

P.S. - attachment

Labels (1)
1 Reply
kaushiknsolanki
MVP
MVP

Hi,

     Try this.

     Date(Date#(Dated,'YYYY-MM-DD')) as Date,

     Year(Date(Date#(Dated,'YYYY-MM-DD'))) as year,

     Month(Date(Date#(Dated,'YYYY-MM-DD'))) as Month

     ...

Regards,

Kaushik Solanki

Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!