Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
flo2
Contributor III
Contributor III

Are there some known issues with for the instruction " each File in filelist (path_Pallet) ?"

Hello,

I have some issues with importing multiple files which begins by the same letters thanks to the instruction " for each File in filelist (path_Pallet) ". 

Because when i create manually one csv file which include all data from  10  other csv files, if I import this file on Qlik, I  have all the data that were in the csv files ( I copy / paste from the files to the big file ) 

 

But when i use the command for each File in filelist (path_Pallet) in script , on my Qlik I see  roughly 97% of the data which where in the files, and i don't understand why  there are some missings, so i wanted to know there was a better way to do it or if there was a known issue.

In my scrit i use it like this :

 

let path_Pallet = '$(Path)P1\document_export*.csv';

 

[temp]:
NoConcatenate
load
[Id... ],
...
resident Former
group by Id,...;

drop table Former;

for each File in filelist (path_Pallet)

 

Labels (2)
4 Replies
marcus_sommer

I'm sure there is no restriction or issue with the filelist(). Each file which fits to the file-pattern will be loaded - means both statements are equally:

load * from [$(path_Pallet)] (txt);

for each file in filelist('$(path_Pallet)')
   load * from [$(file)] (txt);
next

Your noconcatenate-statement and/or the aggregation within the load could have an impact. I suggest to check the applied logic in regard to loading + preparing the data-set and aggregating + merging the entire data-set afterwards to see if there is any difference. By using such approach you could add filebasename(), recno() and rowno() within the loads to make absolutely clear which data came from which source and if there are unexpected results you could track them easily.

- Marcus

flo2
Contributor III
Contributor III
Author

Thanks will try to change how it is done currently and remove the noncatenate aggregation

and will see if is solved

GeigerS
Contributor
Contributor

Counting the rows in a table and assigning the number to a new field · Are there some known issues with for the instruction " each File in filelist 

MyFamilyMobile

marcus_sommer

No.