Qlik Community

Ask a Question

New to Qlik Sense

If you’re new to Qlik Sense, start with this Discussion Board and get up-to-speed quickly.

Announcements
Qlik Users, make your voice heard! Participate in Wisdom of Crowds® Market Study: Start Survey
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

If load

If nooffailures=0

Load

calendarkey...

where  calendarkey=today()>today()-120;

else

Load

calendarkey...

where  calendarkey=today()>today()-90;

Can any one suggest how to do this requirement.

5 Replies
jcramirez472
Partner
Partner

Can you explain the requirement further? It looks like you want to load a different number of days based on a variable.

atkinsow
Specialist II
Specialist II

Something like this maybe.

if nooffailures=0 then

     let vDateCount=today()-120;

else

     let vDateCount=today()-90;

ENDIF;

Load

     calendarkey

From Yourfile

where calendarkey<today()+1 and calendarkey>$(vDateCount);

Update:  Had to edit for the variable.

atkinsow
Specialist II
Specialist II

Did you get your answer?

Not applicable

Thanks really very good help.

atkinsow
Specialist II
Specialist II

Then please close thread by marking a response as the answer.

Qlik Community Tip: Marking Replies as Correct or Helpful