Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

Announcements
Modernize Your QlikView Deployment webinar, Nov. 3rd. REGISTER
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Creator II
Creator II

How to get date and time stamp of file in a location

I have a location suppose c/files/

Here I have 4 files namely a.csv, b.csv, c.csv and d.csv

I want to check the time and date of the files in the drive and proceed the script only if the file has changed.

How do I check that?

The logic would be:

read file date and timestamp,

if file has changed, read the file, otherwise skip script execution.

Could someone suggest me an approach for that please.

Thanks

Sujit!

Labels (1)
3 Replies
Highlighted

Use the filetime function in the load script.             filetime(filename)

File Functions
https://help.qlik.com/en-US/qlikview/November2017/Subsystems/Client/Content/Scripting/FileFunctions/...

Highlighted
Creator II
Creator II

For a big file, it takes lot of time. It actually reads all rows then returns time which is not as expected.

Is there a faster way to get the time?

Thanks!!

Highlighted
Creator II
Creator II

Also I can use a variable to see the filetime, but how do I store it in a file that can be read to check if the file has changed or not.

Thanks!!