Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

sunil1989
New Contributor

Generating Multiple Qvd

Hi ,

Thanks in advance!!!!

My requirement is that i have two variable vStartDate And vEndate,

For example I have pass date to these variables vStartDate = 04-05-2017 and vEndate = 08-05-2017.

and my query is

$(vTableName):
SQL
SELECT * FROM
$(vTableName)

where DAY_KEY >= $(vStartDate)
and DAY_KEY <=
$(vEndDate);


and it should store the data for each day in diffrent qvd for example:

$(vTableName)_04-05-2017.qvd

$(vTableName)_05-05-2017.qvd

$(vTableName)_06-05-2017.qvd

$(vTableName)_07-05-2017.qvd

$(vTableName)_08-05-2017.qvd;


2 Replies
MVP
MVP

Re: Generating Multiple Qvd

prieper
Honored Contributor II

Re: Generating Multiple Qvd

Basically the syntax seem to be ok, however it always depends on the content of your variables (and the SQL-interpreter). Suggest to check the script without using variables and then adopt your variables for the required syntax. With our database we needed to convert dates into a string with the format YYYY-MM-DD.

for the second question:

STORE $(vTableName) INTO $(vTableName)_$(vStartDate).qvd (QVD);

should do. Probably you may have to hand over a directory for the saving-location.

Regards

Peter