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

Announcements
Join us to spark ideas for how to put the latest capabilities into action. Register here!
cancel
Showing results for 
Search instead for 
Did you mean: 
nachiket_shinde
Contributor III
Contributor III

Adding new columns to QVD Generator without impacting old QVDS

I have a generator which generates QVDS on daily basis with date appended to filename

eg

xyz_20171001

xyz_20171002

xyz_20171003 and so on.

Stored at same folder

Then I have a DM where in I am calling each QVD, performing some transformations.And then creating 1 QVD out of it.

Then in my application I am using this newly created QVD.

Question:

I want to show 3 new columns in Application. So if I add them from today then DM will fail saying columns are not available in QVDs created previously.

I dont want to have those columns in old Qvds but new Qvds should have them.

Please suggest.

Please let me know if I am not clear.

13 Replies
kenphamvn
Creator III
Creator III

Hi

Did you try script

noconcatenate

[Templatetable]:

Load *

from xyz_YYYYMMDD.QVD

where 1=2; //any table, just get struct only

For each filename in filelist

concatenate (Templatetable)

Load *

from $(filename).qvd (qvd)

loop

Number of column in Templatetable will be max of column of table in list and auto add missing column with null value

Regards

rwunderlich
Partner Ambassador/MVP
Partner Ambassador/MVP

If you use "Load *" you don't have to worry about the number of columns. Is your load more complex than that?

-Rob

rwunderlich
Partner Ambassador/MVP
Partner Ambassador/MVP

An,

There is no need to add null() for the missing columns. That will be done by default.

-Rob

nachiket_shinde
Contributor III
Contributor III
Author

LOAD *,

Transformations;

LOAD *,transformations;

LOAD transformation(Fields)

FROM xyz_date.qvd

WHERE

Condition

Currently it has 50 columns

from today new qvds will have 52 columns

how can I include these extra 2 columns in above script