Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello, I want to delete all the CSV files at the end of my loading of data that I have in this directory: lib://APPS/*.csv
I saw by looking a bit that it was possible to delete files in a folder using a macro.
However I do not know how to insert a macro under QLIK SENSE and especially I do not know if QLIK SENSE takes into account the macro.
Thanks in advance 🙂
As far as I know, Qlik Sense doesn't support macro's. So deleting a file out of a Qlik Sense script isn't possible, I think.
Hello Timpoismans,
Thanks you for you reply.
I use this script but it's doesn't works :
LET vFileDate = Date(Left(right(file,28),8)); // Gets the year portion from the filename LET vMaxDate = Rangemax(vFileDate, vMaxDate); // Gets the max year for every iteration if filesize('lib://DATA_Imports (omnium_istya4)/APPS Approvisionnement Logvad/$(vMaxDate).csv') > 0 then EXECUTE cmd.exe /c del $(vMaxDate).csv; end if;
Yes, this was an option that you could select in the settings of QlikView.
But Qlik Sense doesn't have any of the settings, so we can't give our app these rights. Thus, we can't delete files in a folder from the script.
Oh ok ! 😕
So it is not possible to delete files from the script for the moment in qlik sense?
Ok thanks you so much for you help
Hi @jmialoundama
I can be done, but you need to change the envioment to legacy mode, NOT RECOMMENDED.
Br.
Teis