Skip to main content
Announcements
Qlik Introduces a New Era of Visualization! READ ALL ABOUT IT
cancel
Showing results for 
Search instead for 
Did you mean: 
jakobjensen
Contributor II
Contributor II

Join syntax on already loaded tables in load editor

In my load-editor I have the following

 

LOAD orderid,
fruit;
[Fruits]:
SELECT fruit, orderid FROM DB.table_fruits;


LOAD orderid,
customerid;
[Customers]:
SELECT orderid, customerid from DB.customers;

 

 

I want to make an inner join on "orderid" in a new table based on the allready loaded tables i.e

 

[Joined_table]:

SELECT * Customers

INNER JOIN Fruits

 

I have tried almost all possible syntax I can think of, but nothing works (https://help.qlik.com/en-US/sense/November2020/Subsystems/Hub/Content/Sense_Hub/Scripting/combine-ta... does not shed some light either)

Labels (2)
1 Reply
QFabian
Specialist III
Specialist III

Hi @jakobjensen , please try this options

//Option A, use of Resident

Fruits:
LOAD orderid,
fruit;
SELECT fruit, orderid FROM DB.table_fruits;

Customers:
LOAD orderid,
customerid;
SELECT orderid, customerid from DB.customers;

[Joined_table]:
Load
  orderid as OrderId,
  fruit as Fruit
Resident Fruits;

INNER JOIN

Load
  orderid as OrderId,
  customerid as CustomerId
Resident Customers;

drop tables Fruits, Customers;


//Option B, just inner join between loads
Fruits:
LOAD orderid,
fruit;
SELECT fruit, orderid FROM DB.table_fruits;

inner join

Customers:
LOAD

orderid,
customerid;
SELECT orderid, customerid from DB.customers;

QFabian