This field is required.
Only these extensions are allowed(.jpg, .JPG, .jpeg, .JPEG, .gif, .GIF, .png, .PNG)
Tags cannot contain the characters ' /, \\, #, ?, or ; >,< '
Only these extensions are allowed(.zip,.ZIP,.pdf,.PDF,.qvf,.QVF,.qvw,.QVW)
Discussion Board for collaboration related to QlikView App Development.
I'm trying to UNION together two tables with different field names on the database server and feed into a QlikView LOAD statement.
The database is an AS400 which is always awkward.
SQL SELECT AKey As MyKey FROM Table1 WHERE AYear >= 2013
SELECT BKey As MyKey From Table2 WHERE BYear >= 2013;
However I get an error stating 'Field not found - <MyKey>'.
Is it possible to do this?
is it work??
SQL SELECT AKey As MyKey FROM Table1 WHERE AYear >= 2013 ;
SQL SELECT BKey As MyKey From Table2 WHERE BYear >= 2013;
Not quite but it has pointed me in the right direction. The statement doesn't like the renaming of the field with the SQL statement. If I rename it in the LOAD statement it works. See below.
[MyTable]:LOAD AKey As MyKey;
SQL SELECT AKey
FROM Table1 WHERE AYear >= 2013 ;
BKey As MyKey;
SQL SELECT BKey
From Table2 WHERE BYear >= 2013;
seems to be there is no issues with your script, it should work..
As I tried the same thing in SQL Server, it is working fine with out any issues...
SQL SELECT DT_SR_KEY as Temp1
FROM DATE_DIM where CLNDR_YR=2014
SELECT FILING_SR_KEY as Temp1
maybe you use qualify?
I think this is another weird thing from the AS400/Iseries. I'm always finding odd issues like this where it works on other platforms.
try this (no preceding load) and after the reload look at the table viewer if your MyKey field is in uppercase
SELECT AKey as MyKey FROM Table1 WHERE AYear >= 2013
SELECT BKey as MyKey From Table2 WHERE BYear >= 2013;
you cannot use concantenate, because this solution is not the same how sql union command.
your solution is ok and works on my server. Works your sql query on sql Server? Booth keys should have the same data type. If sql querey works, buth QlikView not, you can try it:
SELECT AKey As MyKey FROM Table1 WHERE AYear >= 2013
SELECT BKey From Table2 WHERE BYear >= 2013
It works for me too