Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
ali_hijazi
Partner - Master II
Partner - Master II

generate a table of dates

Hello

I want to generate a table of dates that start from today and goes back until the first date of a year specified by number of years to go back

this number is to be taken from an input box on a sheet

thank you

I can walk on water when it freezes
1 Solution

Accepted Solutions
erichshiino
Partner - Master
Partner - Master

Hi,

I used the following script:

Table:

load date( makedate($(vStartYear))+rowno()-1) as Date

AutoGenerate( today()-makedate($(vStartYear))) ;

vStartYear is a variable available on an input box.

You can also check the attachment.

Hope it helps,

Erich

View solution in original post

2 Replies
erichshiino
Partner - Master
Partner - Master

Hi,

I used the following script:

Table:

load date( makedate($(vStartYear))+rowno()-1) as Date

AutoGenerate( today()-makedate($(vStartYear))) ;

vStartYear is a variable available on an input box.

You can also check the attachment.

Hope it helps,

Erich

kaushiknsolanki
Partner Ambassador/MVP
Partner Ambassador/MVP

HI,

    I am here by uploading an example.

    I hope this is what you are looking.

Regards,

Kaushik Solanki

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