Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I want to only load the last 10,000 rows in my data set, where Status='R'. Is there a simple way to do this?
Is there a date field to identify the most recent records?
If there is you could use something like
FIRST 10000
LOAD
... ;
SQL select
...
From ....
Where Status = 'R'
Order by your_date_field desc ;
Is there a date field to identify the most recent records?
If there is you could use something like
FIRST 10000
LOAD
... ;
SQL select
...
From ....
Where Status = 'R'
Order by your_date_field desc ;
You can load the FIRST x number of rows :
FIRST 10000
LOAD ...
So, if you sorted your data in a descending order (based on a date/time, or an ID) then you could limit your load to the last x number of rows.
cheers,
Oleg Troyansky
QlikView Your Business: An expert guide to Business Discovery with QlikView and Qlik Sense
Jinx!
This works perfect. but the Load is loading the first 10,000 with and with out the 'Order by' statement.
I am Ordering by ROWID. in this case i get row 1-10000
I did order by -ROWID
that gave me the right answer.
Have you tried ordering in descending order?
ORDER BY ROWID DESC
Just did. This also works. Thank you!