Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi all,
Please advise on UNION All in Select query,How to use:
Select
Details1 as Details,
a,
b,
c
From A
UNION ALL
Select
Details2 as Details,
a,
b,
c
From B;
Above statement is not working in load script.
I want to extract data with a select statement
for performance tuning.
Thanks for help
Nitha
Hi,
First load single table if it is loading single table, then include SQL keyword like below, hope this is the issue
Data:
SQL SELECT
Details1 as Details,
CONTROL_KEY ,
PKEY,
LKEY,
'1’ as Identifier
From RSID
UNION ALL
SELECT
Details2 as Details,
CONTROL_KEY ,
PKEY,
LKEY,
'2' as Identifier
FROM RSIF
UNION ALL
SELECT
Details3 as Details,
CONTROL_KEY ,
PKEY,
LKEY,,
'3' as Identifier
FROM RSIG;
Regards,
Jagan.
Use Concatenate
Replacement for union
Select
Details1 as Details,
a,
b,
c
From A
concatenate
Select
Details2 as Details,
a,
b,
c
From B;
Regards
ASHFAQ
It is possible you ODBC non suport this.
Try with JOIN or CONCATENATE
Nitha,
Try the query first directly on the backed and see if it works?
What error message are you getting?
thanks,
Rajesh Vaswani
Hi Ashfaq,
I want to extract data from multiple tables with select statement at the same time so data will be extracted in single table to qlikview.
so concatenate can be done only after extracting all tables to qlikview.
Thanks
Nitha
Hi Rajesh,
Yes i have queried in backend and used same query in qlikview script.
But still it doesn't work
Thanks
Nitha
There is no error and only first table is extracted
What is the source database system?
- Ralf
Hi Ralf,
Its oracle.
Check if you have given SQL and terminated with quote. Otherwise it should work. Could be possibly to do with the driver then.
thanks,
Rajesh Vaswani