Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello all,
How do i load (Qlik script) all columns from the the latest modified ,qvd from a specific folder?
I saw multiple simmilar open topics on Community, but without correct anserws.
Regards,
Andrei
FOR Each File in FileList('<path>')
AllQVDs:
LOAD
'$(File)' AS QVD,
FileTime('$(File)') AS QVDModifiedDate
AutoGenerate(1);
Next File
NewestQVD:
FIRST 1 LOAD
QVD,
QVDModifiedDate
RESIDENT AllQVDs
ORDER BY QVDModifiedDate DESC;
DROP TABLE AllQVDs;
This will result in a table with 1 record containing the newest QVD
Use Peek or Lookup to get the value of the QVD and load from this path.
hope this was clear enough
Load first time or Reload ?
can you elaborate little bit more??
what is your folder structure??
in which way you are storing file?
Regards
Load the latest file of a folder
can You check this it may be useful
Hi In general if we will get new files always and we need to load latest file.
We need to write script to move existing file to Archive file and then place new fiel in the current load folder:
Lets assume here are the files & folders available in load folder:
Archive
sample_20180326.xlsx
so now if we assume we have new file "sample_20180327'.xlsx, in general we will write a script to move existing 'sample_20180326.xlsx' to archive folder and then place the new file 'sample_20180327.xlsx' into load folder
In general we will ask stake holders to do the work manually or we will automate using some script
load first time.
this is how my folder looks.
I want to load only the last modified file (18_03_26-1600)
it's a folder from my local sharepoint. i want to load some columns from the last modified .qvd file.
each day 2 new .qvd files are appearing in this folder. when i load data, i want to load the last modified .qvd.
Use a filelist loop to get all files in the folder and then read the modified date to determine which one you want with load first and order by modified date. This approach does not work if the files are never archived. As the reload will take longer everyday (retrieving the filelist)
yes, great theory, but i'm using qlik only for 2 months and i don't know all functions