Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

How to write this expression in Qlik?

do you know how can i write in qlik language this  expresssion below.  I'm still debutant in qlik . thank you

if(calendar1.Date=getcurrentselection(),calendar2.Date=(calendar2.Date<calendar1.Date))

4 Replies
arasantorule
Creator III
Creator III

Hi,

Can you briefly explain your requirement in words.

Thanks.

Not applicable
Author

hello,

i have 2 dimensions calendar. calendar1 contain field date1, calendar2 contain field date2. i want when i select one date to date1(example 12/052016). In calendar2, it show me date which possible selected (date2<date1 possible selected)

example in date2 possible selected are (09/05/2016,10/05/2016,11/05/16).

thank you for your help

arasantorule
Creator III
Creator III

Hi,

Am I correct to say that, when you select the date "calendar1.Date", you want to show the previous dates in "calendar2.Date".


Do you have 2 calendars in the Application and if so, are they linked to each other?

Thanks.

Not applicable
Author

yes i have 2 calendar in my application , the information are the same. link between calendar1 and calendar2 is field date

calendar1:

Load

TempDate AS date1,

TempDate AS date,

week(TempDate) As Week,

Year(TempDate) As Year,

Month(TempDate) As Month,

MonthName(TempDate) as MonthYear,

Day(TempDate) As Day,

ApplyMap('QuartersMap', month(TempDate), Null()) as Quarter,

Week(weekstart(TempDate)) & '-' & WeekYear(TempDate) as WeekYear,

WeekDay(TempDate) as WeekDay

Resident TempCalendar

Order By TempDate ASC;

Drop Table TempCalendar;

calendar2:

Load

TempDate AS date2,

TempDate AS date

Resident TempCalendar

Order By TempDate ASC;

Drop Table TempCalendar;

thank you for your help