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: 
Not applicable

Difference between left keep and left join

Hi everyone,

I am looking at an old script in my company. The guy who wrote it used a lot of "LEFT JOIN" whereas there is no specific conditions for joining, it's always natural joins. In that case why to use "LEFT JOIN" instead of "LEFT KEEP" which would keep 2 separate tables ?

Is there an advantage that I don't see ?

How do you choose between left join and left keep ?

What do you think ?

Thank you

4 Replies
Not applicable
Author

Hi Laura,

I think it would help to understand the different outputs you get from the two different options.

This thread might be a good read

http://community.qlik.com/groups/qvscriptor-from-schema-to-script/blog/2011/11/11/understanding-join...

hope that helps

Joe

Not applicable
Author

Hi Joe,

Thank you for your answer. I do understand that with a keep, there will still be 2 separate tables but what is better? To have only one "big" table or to keep separates tables ? How to choose ?

I haven't deeply checked but I don't think there are any differences in the 2 outputs I get with the 2 options. I am just wondering if one is better in term of performance and speed of the execution.

Not applicable
Author

It depends on the data model. Having one big table can be more resource sparing, but there can be instances where is more logical keeping two table when data types or their meaning differ.

Br,

T

sujeetsingh
Master III
Master III

Laura,

better to follow joins.

But actually it more depends on the requirement.