Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
knightwriter
Creator III
Creator III

Creating a link between two .QVD

Hi All,

I have two QVDs that need to link together so I can create various charts, tables, etc on the back off this match.

The Opportunity.qvd should contain the date field [Opportunity_StageAudit.Date], which is contained in the Opp_stage.qvd.

How do I do this in the script?

All help much appreciated

1 Solution

Accepted Solutions
Miguel_Angel_Baeyens

You need to use the JOIN LOAD in order to "merge" two tables, very similar to what you would do with SQL. Loading the files with the same field will associate them, so unless you need to join both tables in a single, bigger one, the results should be correct

View solution in original post

9 Replies
Miguel_Angel_Baeyens

If the rest of the fields in each QVD have a different name, do a

Stage:

LOAD *

FROM Opp_stage.qvw (qvd);

Opp:

LOAD *

FROM Opportunity.qvd (qvd);

And that will load both tables so you can start with the charts and analysis

krishnacbe
Partner - Specialist III
Partner - Specialist III

Hi,

If the Date Format is same in two QVDs and [Opportunity_StageAudit.Date] is the only Key field in both QVDs you can directly load two QVDs. Qlik will join two tables with common field.

If you are looking for more details, share the Sample Data.

knightwriter
Creator III
Creator III
Author

Hi Miguel,

Thanks for the response. Will that do the join between the two tables? As below, the other calendars are linked to the Opportunity table and I am looking to join the table on the right (Stage_Calendar) to the Opportunity table via the date field [Opportunity_StageAudit.Date]. Thanks

knightwriter
Creator III
Creator III
Author

Thats the issue, the [Opportunity_StageAudit.Date] is one QVD and not the other. Im looking to create a join between the two.

There is infact an Opp_ID filed that is common to both tables - could I join this way via the script?

krishnacbe
Partner - Specialist III
Partner - Specialist III

[Stage Change Date] and  [Opportunity_StageAudit.Date] have same format and if you wish to join using these two dates you can just use  [Stage Change Date] as [Opportunity_StageAudit.Date] while loading the second table.

If the Opp_ID exist in two tables automatically join will be done, if name is different you need to RENAME any one field in any one table.

For Example:

Stage:

LOAD *,

[Stage Change Date] as  [Opportunity_StageAudit.Date]

FROM Opp_stage.qvw (qvd);

Opp:

LOAD *

FROM Opportunity.qvd (qvd);

knightwriter
Creator III
Creator III
Author

[Opportunity_StageAudit.Date] is in the Stage_Calendar table and Opportunity table.

How do I join the [Opportunity_StageAudit.Date] to the Opportunity table to create the join?

krishnacbe
Partner - Specialist III
Partner - Specialist III

Hope you have qualified the Opportunity Table. Unqualify the [Opportunity_StageAudit.Date] in the Opprotunity Table to do the automatic join.

Wrote below statement after the Opportunity table load.

UNQUALIFY  [Opportunity_StageAudit.Date];

ziadm
Specialist
Specialist

Miguel_Angel_Baeyens

You need to use the JOIN LOAD in order to "merge" two tables, very similar to what you would do with SQL. Loading the files with the same field will associate them, so unless you need to join both tables in a single, bigger one, the results should be correct