Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

How to create monthly QVD ?

I have a qvd file that i need to create from monthly qvd like " 201601.qvd "

How can i do this ?

46 Replies
sushil353
Master II
Master II

Temp:

LOAD distinct MonthStart(Date) as DateTemp  

FROM

source.qvd

(qvd);

let Vm=NoOfRows('Temp');

for I=0 to $(Vm)-1;

LET vFileName=Date(Peek('DateTemp',$(I),'Temp'),'YYYYMM');

Let vMonthFilter  = Peek('DateTemp',$(I),'Temp')

noconcatenate

Temp2:

Load * From source.qvd(qvd)

where MonthStart(Date) = '$(vMonthFilter)'

STORE  Temp2 into $(vFileName).qvd (qvd);

drop table Temp2;

NEXT I;

Updated the code:

In first table I am taking distinct monthstart so it will get only single month start date.

It is better if you post some sample data.

Not applicable
Author

This did it, thank you !

susovan
Partner - Specialist
Partner - Specialist

You can also try this process,

Table1:

LOAD *,

Date(Today(),'YYYYMM') as @_Date;

LOAD Date,

     Product,

     Sales

FROM

[01-06-2016.xlsx]

(ooxml, embedded labels, table is Sheet1);

let Vm=NoOfRows('Table1');

for i=0 to $(Vm)-1;

LET Vmonth=Date(Peek('@_Date',$(i),'Table1'),'YYYYMM');

STORE Table1 into D:\PERSONAL\Qlik Community\Save as particular qvd File name\ $(Vmonth).qvd;

Warm Regards,
Susovan
qlikview979
Specialist
Specialist

Hi Bro ,

How can i Add color Script in community?

Regards,

Mahesh

Not applicable
Author

Hi, this just took this months Date . so i got a result of 201606.qvd, not the previous months. which i need also.

tamilarasu
Champion
Champion

Hello Mahesh,

Simple. First, you need to change your edit script font color. You can read below blog post to know more about it.

Colorful QlikView Scripts & Expressions

Once you change the font colors, copy paste your script in word file. Now, you can paste the script in your questions/ replies.

tamilarasu
Champion
Champion

No problem Akintosh . Gud night all.