Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Good day!
In my test model i have simple table:
Main:
load
City
from
City.xlsx
(ooxml, embedded labels, table is Sheet1);
City |
City1 |
City2 |
City3 |
City4 |
City5 |
City6 |
City7 |
I need to create some flag in load script, which will have such values:
1. All cities - in this case it will filter all cities
2. w/o third - in this case it must exclude value City3
Thanks.
Try something like this
Main:
LOAD City
FROM
City.xlsx
(ooxml, embedded labels, table is Sheet1);
Final:
load *,
'All Cities' as Flag
Resident Main;
Concatenate (Final)
load *, 'w/0 third' as Flag
Resident Main
where City<>'City3'
order by City;
DROP Table Main;
I need to create some flag in load script, which will have such values:
1. All cities - in this case it will filter all cities
2. w/o third - in this case it must exclude value City3
I don't understand what you're trying to do. Why do you need a flag field? Why not simply let the user select the cities or use bookmarks?
test:
load
City
from
City.xlsx
(ooxml, embedded labels, table is Sheet1);
Final:
Load RowNo() as No, City Resident test Order By City;
Left Join (Final)
Load City, '1' as Flag1 Resident test;
Left Join (Final)
Load City, '2' as Flag2 Resident Final Where No <> 3 Order By City;
Drop Table test;
Try something like this
Main:
LOAD City
FROM
City.xlsx
(ooxml, embedded labels, table is Sheet1);
Final:
load *,
'All Cities' as Flag
Resident Main;
Concatenate (Final)
load *, 'w/0 third' as Flag
Resident Main
where City<>'City3'
order by City;
DROP Table Main;
after load Where city<> 3 Order By City