Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I have one table loaded from an SQL database and one table loaded from an Excel sheet.
The structure is as follows:
Sheet1:
LOAD SMV,
Description,
..
..
..
FROM
(ooxml, embedded labels, table is [Sheet]);
Table1:
LOAD "STAFF_NR"
"JOB_DESC",
..
..
SQL SELECT * FROM Table1;
In Table1 I want to add a new field called "VER", it should compare JOB_DESC from Table1 with Description From Sheet1. When the condition is true, a "1" must be returned, otherwise "0".
In table1 I should add the following statement in Table1:
IF(JOB_DESC = Description,'1','0') as "VER"
How can I make sure that the field Description is known within Table1?
Is it by the use of resident?
Hi,
Try this.
Sheet1:
LOAD SMV,
Description,
..
FROM
(ooxml, embedded labels, table is [Sheet]);
Left join
LOAD "JOB_DESC" as Description,
"JOB_DESC";
SQL SELECT * FROM Table1;
NewSheet:
Load *,
IF(JOB_DESC = Description,'1','0') as "VER" resident Sheet1;
Drop table Sheet1;
Regards,
Kaushik Solanki