Qlik Community

Ask a Question

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

Announcements
Support Cases coming to Qlik Community Oct. 4! Start chats, open cases, explore resources: READ DETAILS
cancel
Showing results for 
Search instead for 
Did you mean: 
dhirajkhodade
Contributor III
Contributor III

record count is different when stored in qvd

Hi 

I am trying to use left join in qlik view like given below

Trades:
LOAD

a,b,c,d

From abc.qvd (qvd);  //it have 85000 records 

left Join (Trades)
LOAD
a,z

From xyz.qvd (qvd); //it has 3,00,000 records which has all the records from abc.qvd

Store Trades into final.qvd;

When I put Trades table in table object on qvw UI it gives me expected result that is all the records from abc.qvd along with new field i.e. z from xyz.qvd and total record count is 85000

 

but when I load all the records from final.qvd in another qvw I am getting some weired number of records which are not equal to 85000 or 3,00,000 

why is this happening ??

 

Labels (2)
6 Replies
jonathandienst
Partner
Partner

If the values of the associated field (a) are not unique in xyz.qvd, then that will cause rows to be replicated when joining. The left join means that only the records that have an existing a value (from abc.qvd) will be loaded.

So if you have non-unique values of a in xyz.qvd, you can expect to get a final result of at least less than 85k rows and not more than 3 084 999 rows.

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
dhirajkhodade
Contributor III
Contributor III
Author

Thanks for quick response @jonathandienst  
But that still does not explain why I am seeing different number of records when I put same table in table object on sheet/UI vs when I store it in another qvd i.e. final.qvd. 

It should have same number of records in both cases right? correct me if I am wrong. 

Arthur_Fong
Partner
Partner

Is there any tables with the same columns in final.qvd table?

I think your final table has auto-concatenated with another table in your final qvw.

To avoid this, try:

noconcatenate

Final:

load *

from final.qvd;

dhirajkhodade
Contributor III
Contributor III
Author

No there are no tables other than final.qvd data because I am loading it in new qvw for testing.

Arthur_Fong
Partner
Partner

Can you try ApplyMap instead of left join?

Brett_Bleess
Support (Former)
Support (Former)

Just wanted to give you a Design Blog post on what Arthur mentioned that may be of some help:

https://community.qlik.com/t5/Qlik-Design-Blog/Don-t-join-use-Applymap-instead/ba-p/1467592

Regards,
Brett

To help users find verified answers, please do not forget to use the "Accept as Solution" button on any post(s) that helped you resolve your problem or question.
I now work a compressed schedule, Tuesday, Wednesday and Thursday, so those will be the days I will reply to any follow-up posts.