Skip to main content
Announcements
SYSTEM MAINTENANCE: Thurs., Sept. 19, 1 AM ET, Platform will be unavailable for approx. 60 minutes.
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

5 dates range selection

Hi Friends,

I have a table as shown below

 

           Id      Date1     Date2     Date3     Date4    Date5
15-Apr5-Jan4-Feb23-Jan20-Jan
21-Feb3-Jan4-May5-Feb9-Jan
35-Mar5-Jan4-Feb23-Jan20-Jan
44-Jan12-Feb12-Mar18-Mar20-Jan
53-Apr3-Jan4-May5-Feb9-Jan
63-May5-Jan4-Feb23-Jan20-Jan
78-May12-Feb12-Mar18-Mar20-Jan

my requirement to fetch all the id from month/date selected till next 60  days. So here i am reading the table row wise .

Note: all the above dates all linked to master calender.

For Example:

if i select April 2016, then it fetch all the id between April and may.

as i read the records row wise, so in that row, if any of the date falls between april and may then that row need to be fetched if not rejected.

so as per the above table when i select april 2016,

i need to fetch the following id

1,2,5,6,7

thanks in advance

3 Replies
sujeetsingh
Master III
Master III

Hey you need to add trigger for this on Month field or Date field. Hence write trigger on select in field action Where Date >=Selected value and Date <= 60+Selected date.Follow this link

Use trigger to select values in one field based... | Qlik Community

Set trigger to select multiple values in a field from a variable

This link below meets your requirement to some extent

Select last 7 Days in QlikView Document

Anonymous
Not applicable
Author

Thanks....

ashishkalia
Partner - Creator
Partner - Creator

You can try this:

STEP1:

Load ID,

        Date1 as Date

Resident Table;

concatinate

Load ID,

        Date2 as Date

Resident Table;

Concatinate

Load ID,

        Date3 as Date

Resident Table;

Concatinate

Load ID,

        Date4 as Date

Resident Table;

Concatinate

Load ID,

        Date5 as Date

Resident Table;

This will make your data in a systematic and more desired manner.

STEP2

Make a master calender.

STEP3

Make a mapping month like:-

LOAD * INLINE [

    Month, MapingMonth

    Apr, Apr

    Apr, May

    May, May

    May, Jun

    Jun, Jun

    Jun, Jul

    Jul, Jul

    Jul, Aug

    Aug, Aug

    Aug, Sep

    Sep, Sep

    Sep, Oct

    Oct, Oct

    Oct, Nov

    Nov, Nov

    Nov, Dec

    Dec, Dec

    Dec, Jan

    Jan, Jan

    Jan, Feb

    Feb, Feb

    Feb, Mar

    Mar, Mar

];

link it with your calander via Month and make selection on Mapping Month.

This may help.

AK