Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

Not applicable

Load Data into QVD File to another QVD file..

Hi All,

How to add new column into existing qvd file?.

For ex,

I have 3 years data into Customer_qvd.qvd (qvd) file in production server, in this qvd file contain Customer_ID,Customer_name,Location,Region_CD …. Reporting purpose now I want add new column in this qvd file.

When I am adding new column before taking backup and new creating  new qvd file, now how load data from old qvd file to new qvd file(qvd to qvd) and how fill the value into new column.Here no data source getting data from like oracle,sql. Cusomer_qvd file maintain historical data.

Regards.

raja.

Tags (1)
1 Solution

Accepted Solutions

Re: Load Data into QVD File to another QVD file..

Use mapping functions to add the new column.

// create the mapping table

NewDataMap:

Mapping load

Customer_ID,

New_field

From <new data source> ;

//reload data and add new column

Customers:

LOAD *,

Applymap('NewDataMap', Customer_ID) as NewFieldName

From Customer.QVD (qvd) ;

//save updated data to qvd

Store Customers into Customer.qvd (qvd) ;

9 Replies
Not applicable

Re: Load Data into QVD File to another QVD file..

Hi All,

Please assit above question.

How to load data into one qvd file another qvd file..

Regards,

Raja.

manojkulkarni
Valued Contributor II

Re: Load Data into QVD File to another QVD file..

Load Customer.qvd first, then do inner join on CustID. Assuming CustId will be unique key to make link between both qvds.

Then re-create customer qvd with final table created after joining necessary data from second table.

MVP
MVP

Re: Load Data into QVD File to another QVD file..

Hi,

Try like this

DataFromQVD:

LOAD

*,

1 AS New Column

FROM Data.qvd;

STORE DataFromQVD into Data.qvd;

Regards,

Jagan.

Not applicable

Re: Load Data into QVD File to another QVD file..

Hi Jagan,

Good Idea, thank you so much.

But i want fill data into new_column also please help me.

Regards,

raja.

MVP
MVP

Re: Load Data into QVD File to another QVD file..

Hi,

Can you come up with a sample data and your expected output, it helps in understanding the scenario.

Regards,

Jagan.

Not applicable

Re: Load Data into QVD File to another QVD file..

Hi Jagan,

That new column adding into hard code value something like “this is reference ID” for all rows. Here no conditional(like where class) at all.

Regards,

Raja.

MVP
MVP

Re: Load Data into QVD File to another QVD file..

Hi,

Try like this

DataFromQVD:

LOAD

*,

“this is reference ID” AS New Column

FROM Data.qvd;

STORE DataFromQVD into Data.qvd;

Regards,

Jagan.

Re: Load Data into QVD File to another QVD file..

Use mapping functions to add the new column.

// create the mapping table

NewDataMap:

Mapping load

Customer_ID,

New_field

From <new data source> ;

//reload data and add new column

Customers:

LOAD *,

Applymap('NewDataMap', Customer_ID) as NewFieldName

From Customer.QVD (qvd) ;

//save updated data to qvd

Store Customers into Customer.qvd (qvd) ;

Not applicable

Re: Load Data into QVD File to another QVD file..

If the new column is just Hard coded value , why you need another big qvd in the first place ?

You can use existing qvd for both purposes.

Community Browser