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

Announcements
Talend Cloud AWS EU Scheduled Outage: Starting Tues 26 May 21:00 CEST with expected completion Wed 27 May 01:00 CEST
cancel
Showing results for 
Search instead for 
Did you mean: 
mhmmd_srf
Creator II
Creator II

Last 25 Months in a single table

Hi All,

I want to create a Table call Prior Months. The field name would be Prior_Month. Where data would be last 25 months based upon current month dynamically.

Like today is 25th Oct, so current month is 2016-Oct. And the Month would  be like bellow:

I created above one using Inline Load. But I want this dynamically.

Thanks,

Sarif

1 Solution

Accepted Solutions
tresB
Champion III
Champion III

Try like:

Load

  Date(MonthStart(Today(),-RowNo()+1), 'YYYY-MMM') as Prior_Months

AutoGenerate 25;

View solution in original post

2 Replies
nabhiram
Contributor III
Contributor III

tresB
Champion III
Champion III

Try like:

Load

  Date(MonthStart(Today(),-RowNo()+1), 'YYYY-MMM') as Prior_Months

AutoGenerate 25;