Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi Everyone,
I am trying to load multiple files in Qlik cloud using the following format from Sharepoint Connection
"FROM [lib://DEV:Office_365_Sharepoint - TEST/Datasource/Care/New Case/Listing/PatientListing*.csv]
(txt, utf8, embedded labels, delimiter is ',', msq);"
File name is PatientListing_DDMMYYYY, and i would like to load all the files.
Can someone please suggest a way to load all these files at once.
Regards
try with underscore
"FROM [lib://DEV:Office_365_Sharepoint - TEST/Datasource/Care/New Case/Listing/PatientListing_*.csv]
(txt, utf8, embedded labels, delimiter is ',', msq);"
or share the error message?
Still Giving error with underscore
Buenos Dias,
Por favor indicar si solucionaron esta novedad..
Gracias
For each File in FileList('$(vFileName) & '\*' & '.csv')
trace $(File);
Load * From [$(File)] (txt, codepage is 28591, embedded labels, delimiter is ';', no quotes);
Next File
I don't think you can do that since this is not a regular Windows folder where you can use wild characters.
You have to enter the names manually or I maybe there is some short of metadata feature where you can list the file names inside your SharePoint.
Hi @anushka_iconresources
Use a loop to iterate through the files.
// Define the file path
LET vFilePath = 'lib://DEV:Office_365_Sharepoint - TEST/Datasource/Care/New Case/Listing/';
// Loop through each file in the directory
FOR EACH vFile IN FileList('$(vFilePath)PatientListing_*.csv')
TRACE $(vFile);
LOAD
*
FROM [$(vFile)]
(txt, utf8, embedded labels, delimiter is ',', msq);
NEXT vFile;
When I try this with my files the vFile var ends up as Null and none of the files are processed. The vFilePath var is correctly assigned to the location of my datafiles. Obviously, since vFile is Null it just skips over my load statements.
// Define the file path
LET vFilePath = '[lib://OCIO Development:DataFiles/';
// Loop through each file in the directory
FOR EACH vFile IN FileList('$(vFilePath)*Data.xls]')
TRACE $(vFile);
Load ...
Next(vFile);
I'm not seeing anything in the docs that would help figure out why that is Null instead of list of filenames.