Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Dear All,
I am rather new to Qlik ETL zone, and I would require your assistance in loading in Qlik Sense scrip, a query which I wrote in MySQL, any suggestions?
"SELECT
c.id AS id,
c.account_id AS vendor,
c.name AS name,
parent.id AS subcategory_id,
grandparent.id AS category_id,
greatgrandparent.id AS supracategory_id,
parent.name AS subcategory_name,
grandparent.name AS category_name,
greatgrandparent.name AS supracateogry_name
FROM food_menu_tags AS c
LEFT JOIN food_menu_tags AS parent
ON c.parent_id = parent.id
LEFT JOIN food_menu_tags AS grandparent
ON parent.parent_id = grandparent.id
LEFT JOIN food_menu_tags AS greatgrandparent
ON grandparent.parent_id = greatgrandparent.id
Thx,
Sorin
"
Hi,
First of all, you need create the data connection.
Your load script shoud be like....
LIB CONNECT TO 'name';
TABLE1:
SELECT * FROM bbdd.table;
etc.. and after make joins, or
LIB CONNECT TO 'name';
TABLE1:
LOAD c1, c2, c3;
SELECT * FROM bbdd.table where condition;
inner/left join
LOAD d1,d2 as c2,d3
SELECT * FROM bbdd.table where condition;
you don´t need statements like ON c.parent_id = parent.id, it´s enough if there fields with the same name.