Qlik Community

Qlik Sense App Development

Discussion board where members can learn more about Qlik Sense App Development and Usage.

Announcements
QlikWorld 2020: Join us May 11 - 14, 2020 in Phoenix, AZ. Register early and save $400. Learn More
soumroy7
New Contributor II

Read QVD names and store in temp table

Hi,

I am currently loading multiple QVDs(12 QVDs for each month) via for Loop in script. Filenames are like:

ABC_2019_01, ABC_2019_02 ..... and so on.

================================================

LET vFile='[ABC_*.qvd]';

FOR EACH vFile in FileList('ABC_*.qvd')

Load * FROM $(vFile)(qvd);

Next vFile;
NEXT vFile;

Till now it works fine. Now I want to read the latest filename (e.g. - 'ABC_2019_09') and store this QVD File Name in a temp table.

Can anyone help me with an example script for this

BR

Soumya

1 Solution

Accepted Solutions
Partner
Partner

Re: Read QVD names and store in temp table

LET vFile='[ABC_*.qvd]';

FOR EACH vFile in FileList('ABC_*.qvd')

Load * FROM $(vFile)(qvd);

 

FileList:

Load 

'$(vFile)' as FileName,

QvdNoOfRecords('$(vFile)') as NoOfRecords,

QvdNoOfFields('$(vFile)') as NoOfFields

Autogenerate 1;

Next vFile;

Plees ekskuse my Swenglish and or Norweglish spelling misstakes

View solution in original post

4 Replies
Partner
Partner

Re: Read QVD names and store in temp table

LET vFile='[ABC_*.qvd]';

FOR EACH vFile in FileList('ABC_*.qvd')

Load * FROM $(vFile)(qvd);

 

FileList:

Load 

'$(vFile)' as FileName,

QvdNoOfRecords('$(vFile)') as NoOfRecords,

QvdNoOfFields('$(vFile)') as NoOfFields

Autogenerate 1;

Next vFile;

Plees ekskuse my Swenglish and or Norweglish spelling misstakes

View solution in original post

soumroy7
New Contributor II

Re: Read QVD names and store in temp table

Thanks a lot. This helps
soumroy7
New Contributor II

Re: Read QVD names and store in temp table

Thanks a lot. This helps alot

Partner
Partner

Re: Read QVD names and store in temp table

That's great to hear.

I usually do something like this for every qvd I store in my extract and transform applications.

Plees ekskuse my Swenglish and or Norweglish spelling misstakes