Skip to main content Skip to complementary content

Left

The Join and Keep prefixes can be preceded by the prefix left.

If used before join it specifies that a left join should be used. The resulting table will only contain combinations of field values from the raw data tables where the linking field values are represented in the first table. If used before keep, it specifies that the second raw data table should be reduced to its common intersection with the first table, before being stored in Qlik Sense.

Information noteWere you looking for the string function by the same name? See: Left - script and chart function

Syntax:  

Left ( Join | Keep) [ (tablename) ](loadstatement | selectstatement)

Arguments:  

Argument Description
tablename The named table to be compared to the loaded table.
loadstatement or selectstatement The LOAD or SELECT statement for the loaded table.

Example:  

Table1

 

A

B

1

aa

2

cc

3

ee

Table2

 

A

C

1

xx

4

yy

QVTable:

SELECT * From table1;

Left Join Sselect * From table2;

QVTable

 

 

A

B

C

1

aa

xx

2

cc

 

3

ee

 

QVTab1:

SELECT * From Table1;

QVTab2:

Left Keep SELECT * From Table2;

QVTab1

 

A

B

1

aa

2

cc

3

ee

QVTab2

 

A

C

1

xx

The two tables in the keep example are, of course, associated via A.

tab1:

LOAD * From file1.csv;

tab2:

LOAD * From file2.csv;

.. .. ..

Left Keep (tab1) LOAD * From file3.csv;

Did this page help you?

If you find any issues with this page or its content – a typo, a missing step, or a technical error – let us know how we can improve!