Qlik Community

QlikView App Development

Discussion Board for collaboration related to QlikView App Development.

Announcements
BARC’s The BI Survey 19 makes it official. BI users love Qlik. GET REPORT
chandinig
Contributor

Creation of Date dimension(master callender)?

Hi ...

can any one help me how to create Date dimension in Qlikview?

Thanks & Regards,

Chandini.G

3 Replies

Re: Creation of Date dimension(master callender)?

Hi,

have a look at below post.

Let varMinDate = num(MakeDate(2000,1,1));

Let varMaxDate = num(MakeDate(2020,12,31));

//*************** Temporary Calendar ***************

TempCalendar:

LOAD

  $(varMinDate) + rowno() - 1 AS Num,

  date($(varMinDate) + rowno() - 1) AS TempDate

AUTOGENERATE

  $(varMaxDate) - $(varMinDate) + 1;

//*************** Master Calendar ***************

MasterCalendar:

LOAD TempDate AS Date,

  Week(TempDate) AS Week,

  WeekYear(TempDate) as TestWeek,

  Year(TempDate) AS Year,

  Month(TempDate) AS Month,

  year(TempDate)&'-'&Month(TempDate) as Year_Month,

  MonthName(TempDate) as YearMonth,

  Day(TempDate) AS Day,

  'Q'&ceil(month(TempDate)/3) AS Quarter

RESIDENT TempCalendar

ORDER BY TempDate ASC;

DROP TABLE TempCalendar;

Store MasterCalendar into MasterCalendar.qvd(qvd);

Regards

ASHFAQ

cabhijit
Valued Contributor

Re: Creation of Date dimension(master callender)?


PFA master Calender script.

MVP
MVP

Re: Creation of Date dimension(master callender)?