Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Posting on Qlik Community is temporarily paused for some users. Thank you for patience and we'll update you soon!
cancel
Showing results for 
Search instead for 
Did you mean: 
smilingjohn
Specialist
Specialist

session

Hi All,

there are many audit files as shown in the figure

Auditlogs.PNG

for different dates which  cannot be taken individually ,

therefore i am writing the below script  please , let me know if this is the correct way to access the files ,

scirptaudit.PNG

?

Thanks in advance

Labels (1)
2 Replies
qlikviewwizard
Master II
Master II

It is correct way.

You can restrict the data to load between dates also.

For example, you wanted load today's date and 3 more previous dates.

You can achive like this:

Capture.PNG

Capture.PNG

BalaBhaskar_Qlik
Master
Master

May be try like this:

for each vFile in FileList('..\Data\*.txt')

     let vQVD = replace(vFile, '.txt', '.qvd');

     if alt(FileSize('$(vQVD)'), 0) = 0 then

          NextFile:

          LOAD

              *

          FROM $(vFile)

          (txt, utf8, embedded labels, delimeter is '\t', msq);

          STORE NextFile INTO [path$(vQVD)]. (qvd);

          DROP TABLE NextFile;

     end if

next

Data:

LOAD

    *

FROM ..\Data\*.qvd (qvd);