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

Announcements
Want to see what's currently in public preview? We've pulled it all together in one place. Check it out here
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Use while and where in loading script

I have the follwing script

AsOfMonth:

load 'Current' as Type,

Month as Month_AsOf,

Month as Month

Resident SalesData;

Concatenate (AsOfMonth)

load 'Rolling 3' as Type,

Month as Month_AsOf,

Month + 1 - IterNo() as Month

Resident SalesData

where promo =1

while IterNo() <= 3//here my problem

;

How to correct it ?

Labels (1)
1 Solution

Accepted Solutions
avinashelite
MVP
MVP

try like this

while (IterNo() <= 3 and promo =1) ;

View solution in original post

2 Replies
avinashelite
MVP
MVP

try like this

while (IterNo() <= 3 and promo =1) ;

swuehl
Champion III
Champion III

I think you can either use a WHERE or a WHILE clause in the same LOAD statement.

If you want to use both clauses, you would need separate / preceding LOAD statements.