Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements
Qlik Analytics Tour 2020 Online. Begins August 10th. Register Today
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Specialist II
Specialist II

Re: Left Keep Vs Left Join

Hi Jagan,

I tried your examples result as

LEFT KEEP

Transaction:

Country ID,  Sales

1, 1000

2, 3000

Countrymaster:

Country ID,  Country

1, USA

2, INDIA

3, UK    

LEFT JOIN

Country ID,  Sales, Country

1, 1000, USA

2, 3000, INDIA

I did not understand difference between LEFT KEEP and LEFT JOIN? (Just difference no of tables)

Can you give brief example if possible.

Thanks,

Nihhal.

Highlighted

Re: Left Keep Vs Left Join

Hi Nikhil,

When you use the left Join functionality as Jagan give example by expression

Transaction:
LOAD * INLINE [
CountryID, Sales
1, 1000
2, 3000  ]
;

CountryMaster:
LEFT JOIN (Transaction)
LOAD * INLINE [
CountryID, Country
1, USA
2, India
3, UK ]
;


You get result single table with data

Left Join2.png

And if you use Left Keep

Transaction:
LOAD * INLINE [
CountryID, Sales
1, 1000
2, 3000  ]
;

CountryMaster:
LEFT KEEP (Transaction)
LOAD * INLINE [
CountryID, Country
1, USA
2, India
3, UK ]
;

You get two tables and join performs but data of same records in the second table that is CountryMaster

Leeft Keep.png

Hope this helps

Regards

Anand

Highlighted
Specialist II
Specialist II

Re: Left Keep Vs Left Join

Hi Anand thanks for writing.

As per above conversations, only difference is number of tables?

I have read 'KEEP' as one of the performance technique.

Regards,

Nihhal.

Highlighted
Not applicable

Re: Left Keep Vs Left Join

HI,

In simple words

-->>Left keep is same like left join ,it does the join but it keeps the table separate in data model.

-->>Left join, joins the two tables and make it one table.

thats the only diffrence.and this technique is helpful as per scenarios that anybody can get.

thanks

Sudhanshu shrivas

Highlighted
Specialist II
Specialist II

Re: Left Keep Vs Left Join

Hi Shrivas,

Thanks for reply.

Can you share which scenario we go for JOIN and which scenario we go for KEEP if possible.

Regards,

Nihhal.

Highlighted
MVP & Luminary
MVP & Luminary

Re: Left Keep Vs Left Join

HI Nihhal,

If you have one to many or many to many relationship then we can use KEEP, because if we use join the records will be duplicated.

Regards,

Jagan.

View solution in original post

Highlighted
Master
Master

Re: Left Keep Vs Left Join

Hi,

left keep and left join gives the same output.the only difference is :

Left Keep : keeps the table separate in data model.

Left Join : merges the tables that are joined

Regards

Neetha

Highlighted
Specialist II
Specialist II

Re: Left Keep Vs Left Join

Hi Jagan,

Thanks for response. It seems to help me if you share small example.

Regards,

Nihhal.

Highlighted
Specialist III
Specialist III

Re: Left Keep Vs Left Join

Hi,

You can close the thread if you got required information.

Regards,

Sasi

Highlighted
Specialist II
Specialist II

Re: Left Keep Vs Left Join

Please see my last reply on this post. So i am waiting for response from jagan.