Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
external data that I want to read has a date column, I want rows where date is Yesterday date, all rows that have last week date, all rows that have last month date..how to do it in Qlikview script? please note, my database is in SQL server
Need help asap
Thanks in Advance
my script is
OLEDB Connect to [provider=SQLOLEDB.1.................................................]
SQL SELECT *
FROM 'abc.DBO.'XYZ' ;
If your table isn't very huge you could use a where-clause within a Preceding Load like:
Load *
where Date = date(today()-1) or
Date = date(floor(weekstart(today())-1) or
Date = date(floor(monthstart(today())-1);
SQL SELECT *
FROM 'abc.DBO.'XYZ' ;
I think the same main-logic (with other functions and probably more efforts) could be applied to the sql-statement when the sql-load is too heavy without filtering.
- Marcus
Thanks Marcus !!!! It Helped !!!