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

Announcements
Qlik GA: Multivariate Time Series in Qlik Predict: Get Details
cancel
Showing results for 
Search instead for 
Did you mean: 
agomes1971
Specialist II
Specialist II

Use max date to load a qvd file

Why with this code isn't getting the file for month 3?

//Carregamento Inicial dos dois primeiros meses do ano

TESTE:

LOAD Name,

     Data

FROM

(qvd);

Concatenate (TESTE)

LOAD Name,

     Data

FROM

(qvd);

TEMP:

LOAD

min(Data) AS MaxDate

RESIDENT TESTE;

LET vMaxDate = date(floor(peek('MaxDate',0,'TEMP')),'YYYY-MM-DD');

LET vMaxMonth = num(month($(vMaxDate))+1,'00');

//Carregamento parcelar

TESTE:

//Add only load * from C:\Users\red_agomes\Desktop\case_2014-03.qvd (qvd);

Add only load * from C:\Users\red_agomes\Desktop\case_2014-$(vMaxMonth).qvd (qvd);

What am i missing?

Regards

André

10 Replies
richard_pearce6
Partner - Specialist
Partner - Specialist

Andre,

For a detailed explination on how to load specific dates from QVD's which are split into monthly files please see this blog: http://community.qlik.com/docs/DOC-6668

I can only assume the error you have is not loading the file (which is why the previous line is commented out), on my example this is overcome by storing the information as text before attempting to use it in the file name.

Regards

Richard