Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
Keyuser
Contributor
Contributor

Only load files filetime() > Date

Hi Guys!

Load many xls files from a folder
(load *, from Folder / *. xls)

But now I have the problem that from a certain date new fields have been added which I would now like to load.

concatenate
load Distinct
newfield
FROM Folder / *. Xls

How can I load only files larger spezific daten?

concatenate
load Distinct
newfield
FROM Folder / *. Xlsm where filetime() >  '01.10.2019'

does not work. QlikView still tries to check all files and of course does not find the new field in the old files.

Thanks.

4 Replies
Anonymous
Not applicable

you need a field containing a date format which identifies the new records
you may 
concatenate
load Distinct
newfield
FROM Folder / *. Xlsm where datefield >  '01.10.2019'

other way if you have an unique identifier /keyfield

concatenate load Distinct
newfield
FROM Folder / *. Xlsm where not exist (unique_identifier)

Brett_Bleess
Former Employee
Former Employee

Michael, did the post help you get something working as needed, or are you still working on things?  If the prior, do not forget to come back to the thread and use the Accept as Solution button to mark the post that helped you get things working.  If you did something different, consider posting that and then mark it, and if you still require help, please leave an update for us.  

The following Design Blog post may give you another avenue as well:

https://community.qlik.com/t5/Qlik-Design-Blog/Loops-in-the-Script/ba-p/1473543

Regards,
Brett

To help users find verified answers, please do not forget to use the "Accept as Solution" button on any post(s) that helped you resolve your problem or question.
I now work a compressed schedule, Tuesday, Wednesday and Thursday, so those will be the days I will reply to any follow-up posts.
Surya
Creator II
Creator II

Hello., LOAD PGMI_KEY_INV, VALUATED_STOCK_INV, DATE( MAKEDATE (RIGHT(RIGHT(FileBaseName(),10),4), MID(RIGHT(FileBaseName(),10),4,2), LEFT(RIGHT(FileBaseName(),10),2)) ,'DD-MM-YYYY') as VALUATED_DATE FROM [C:\Qlikview Primary\JSPL\Module Wise Base Data Modeling\MM\QVD\Daily Store\VALUATED_INVENTORY_GWI_*.QVD] (qvd) where DATE( MAKEDATE (RIGHT(RIGHT(FileBaseName(),10),4), MID(RIGHT(FileBaseName(),10),4,2),LEFT(RIGHT(FileBaseName(),10),2)),'DD-MM-YYYY') = date(Today(),'DD-MM-YYYYY'); ; May Be help full to u this
Arthur_Fong
Partner - Specialist III
Partner - Specialist III

Try this:

FROM Folder / *. Xlsm where filetime() >  date#('01.10.2019','DD.MM.YYYY')

 

FROM Folder / *. Xlsm where filetime() > '01.10.2019'

This doesn't work since '01.10.2019' is a string, it couldn't be evaluated.

Eg:

filetime()>'abc'. It doesn't work that way.

 Using date#('01.10.2019','DD.MM.YYYY') will evaluate '01.10.2019' as a date format.

Then, you may use where clause to evaluate filetime() accordingly.

Thanks and regards,

Arthur Fong