Skip to main 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 QlikView.

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:  

Table load 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:  

Example 1A

Table1

-

A

B

1

aa

2

cc

3

ee

Example 1B

Table2

-

A

C

1

xx

4

yy

QVTable:

SELECT * From table1;

Left Join Select * From table2;

Example 1C

QVTable

-

-

A

B

C

1

aa

xx

2

cc

 

3

ee

 

QVTab1:

SELECT * From Table1;

QVTab2:

Left Keep SELECT * From Table2;

Example 1D

QVTab1

-

A

B

1

aa

2

cc

3

ee

Example 1E

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;

Join the Analytics Modernization Program

Remove banner from view

Modernize without compromising your valuable QlikView apps with the Analytics Modernization Program. Click here for more information or reach out: ampquestions@qlik.com