Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Change FileName while Loading

Hi all,

For automation in Qlikview, first step i want to remove all timestamps from file while loading  the first time while generating QVD.

Eg...I have a file say ABC_20121221.txt.

I want to trim this

LOAD *FROM ABC_20121221.TXT;

I just want Load * from ABC.txt;

Is there a way to do in qlikview?

Thanks

Khushboo

1 Solution

Accepted Solutions
marcus_sommer

I think it's not a good idea to remove the timestamp from the filename and it's not necessary. You could load with a wildcard like:

LOAD * FROM ABC_*.TXT;

And if this not suits all requirements then you should load your data per filelist - see here an example: Loops in the Script.

- Marcus

View solution in original post

6 Replies
PradeepReddy
Specialist II
Specialist II

Load * from subfield(filename,'_',1)&'.txt';

ahbzshk07
Contributor III
Contributor III

do that only if that file exists at the relative path...

marcus_sommer

I think it's not a good idea to remove the timestamp from the filename and it's not necessary. You could load with a wildcard like:

LOAD * FROM ABC_*.TXT;

And if this not suits all requirements then you should load your data per filelist - see here an example: Loops in the Script.

- Marcus

Peter_Cammaert
Partner - Champion III
Partner - Champion III

Do you really need to rename those files? Can't you just ignore the timestamp (you'll be generating a qvd in any case) and load them all like this?

LOAD * FROM ABC*.Txt (options);

Not applicable
Author

this does not wok for me ... Does it work for you ... Can you post sample

PradeepReddy
Specialist II
Specialist II

It won't work.. its my overlooking..