Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements
Customers, Partners & Luminaries only: You're invited to a Data Analytics Roadmap session. Read More
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Specialist II
Specialist II

Its tricky date reqiurment

set DateFormat='M/D/YYYY';

Let vStart =  Date('4/30/2010') ;

Let vEnd = Date('1/31/2014');

MonthCal:

Load Date(Date-1) as Date ,RowNo() AS  DateID;

Load  Date('$(vStart)' + RecNo() ) as Date autogenerate '$(vEnd)' - '$(vStart)';

from above script i have created a dynamic dates and using RowNo() as DateID defined id for dates ,So here I want monthEnd dates that is also fine I created MonthEnd(Date ) it list out only MonthEnd Dates .I Want That Month End Date Ids to be Created Can any help me out  .

1 Solution

Accepted Solutions
Highlighted
MVP & Luminary
MVP & Luminary

MonthCal:

Load

Date(Date-1) as Date ,RowNo() AS  DateID ,

Autonumber(monthend(Date-1)) as MonthEndID;

Load  Date('$(vStart)' + RecNo() ) as Date autogenerate '$(vEnd)' - '$(vStart)';


talk is cheap, supply exceeds demand

View solution in original post

5 Replies
Highlighted
MVP & Luminary
MVP & Luminary

MonthCal:

Load

Date(Date-1) as Date ,RowNo() AS  DateID ,

Autonumber(monthend(Date-1)) as MonthEndID;

Load  Date('$(vStart)' + RecNo() ) as Date autogenerate '$(vEnd)' - '$(vStart)';


talk is cheap, supply exceeds demand

View solution in original post

Specialist II
Specialist II

No Syntax error Autonumber(monthend(Date-1)) as MonthEndID;

Highlighted
Not applicable

The answer by Gysbert Wassenaar is correct

Add just a comma (,) after DateID (surely due to a bad copy/paste)

Fabrice

Highlighted
Not applicable

Hi,

ADD comma ',' instead of semicolun ';' next to MonthEndID.


Highlighted
Specialist II
Specialist II

thanks a  lot Gysbert  its working but still i need to do some work fo finish it.

In chart i taken  MonthEnd(Date) as Dimension  so if i select a year 2011 its shows only that value .i want to be show previous year as well up to April 2010 in same way all years its possible or any other valuable solutions Please share these as soon as possible.