Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I have this script and it is not working.
tan:
LOAD * INLINE [
F1, F2
09/07/2021, ren
09/05/2021, rte
];
tan1:
load * Resident tan
Where F1 > date('09/06/2021', 'MM/DD/YYYY');
DROP TABLE tan;
I was expecting the table 'tan1' to have only the first row but tan1 is not even getting created.
what is wrong with it?
Thanks
Try this
tan:
LOAD * INLINE [
F1, F2
09/07/2021, ren
09/05/2021, rte
];
noconcatenate
tan1:
load * Resident tan
Where F1 > date('09/06/2021', 'MM/DD/YYYY');
DROP TABLE tan;
Try this
tan:
LOAD * INLINE [
F1, F2
09/07/2021, ren
09/05/2021, rte
];
noconcatenate
tan1:
load * Resident tan
Where F1 > date('09/06/2021', 'MM/DD/YYYY');
DROP TABLE tan;
Just to add some context to this reply (which is right), in Qlikview, when you load a table that has exactly the same column names as a previous table it gets "concatenated" to the previous table.
So what your code is doing is concatenating or unioning tan and tan1 so that they become one table called "tan" and then you're dropping that table.
If you remove the drop table statement you'll see that the tan table actually has three rows which represents the merging of the two datasets you loaded
Hi @jduluc12
For your scenario, you can directly use where condition in first load itself.
tan:
LOAD * INLINE [
F1, F2
09/07/2021, ren
09/05/2021, rte
]Where F1 > date('09/06/2021', 'MM/DD/YYYY');
If you are doing some manipulation, then you can use resident load.