Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello guys, I have the following case:
I have several excel files that I want to upload to Qliksense but I want to upload them without the *
The File has the date for example: 202301, I currently loads with 2023* but I would like to know if there is a possibility to replace the * by a variable that auto-increments and reads the files that are available
Thank you
Hi,
you can include your load statement inside a loop which loops through the months you want to load. At the end of each iteration, the vPeriod-variable is increased by 1 using the AddMonths() function.
For example:
set vPeriod = 202301;
for i = 1 to 12
load
Field1,
Field2
from [lib://AttachedFiles/Report $(vPeriod).xlsx]
(ooxml, embedded labels, table is Report);
let vPeriod = date(addmonths(date#($(vPeriod), 'YYYYMM'), 1), 'YYYYMM');
next
Hope that helps.
Kind regards from Brussels,
Thilo
Hi,
you can include your load statement inside a loop which loops through the months you want to load. At the end of each iteration, the vPeriod-variable is increased by 1 using the AddMonths() function.
For example:
set vPeriod = 202301;
for i = 1 to 12
load
Field1,
Field2
from [lib://AttachedFiles/Report $(vPeriod).xlsx]
(ooxml, embedded labels, table is Report);
let vPeriod = date(addmonths(date#($(vPeriod), 'YYYYMM'), 1), 'YYYYMM');
next
Hope that helps.
Kind regards from Brussels,
Thilo
thanks