Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

QlikView Fans! We’d love to hear from you.
Share your QlikView feedback with the product team… Click here to participate in our 5-minute survey.
Rules, plus terms and conditions, can be found here.
Not applicable

Add date to data in the script


I need to analyze the model by year quarters and months.

Sales table between 2007 - 2010 and the budget table should be the same every year.

Can someone show me how to add it to the script?

2 Replies
Not applicable

Re: Add date to data in the script

You can create the Year field by : Year(DateField) AS Year

and Quarter by: Q & Ceil(Month(DateField)/3) AS Quarter

Not applicable

Re: Add date to data in the script

Or You can create the Master Calender Table and connected the Calender Table through your Date field.



          Year(DATEFIELD) AS YEAR,

          Month(DATEFIELD) AS MONTH

          'Q' & Ceil(Month(DATEFIELD)/3) AS QUARTER,

          Week(DATEFIELD) AS WEEK



Resident From SALES_TABLE;

You can any other calender fields to CALENDAR table if you need.

Community Browser