Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All,
I have two tables.
One is DATE Dimension Table and another Table Contains the latest date of data arrival.(LATEST Date Table)
I need to pick this latest date from the 2nd table and match this with the 1st table that is DATE Dimension table
and obtain the last 8 weeks from the DATE DIMENSION TABLE.
I am attaching the sample data set. Plz have a look on it.
Thank You
Sorry maybe im not understanding your query very well but one option, if you have a master calender (which could be what date dimension table is ) is to just put a couple listbox of YEAR and MONTH and then you can just select the last 2 months.
Thanx Lee for reply............
But If I need to pick Last 2 or 3 Weeks.............Then ??
then id set up your master calendar in the following fashion and you can select however you want really. Or use your set analysis around which ever week or months youre after
dateid | date | year | month | weekno |
1 | 01/01/2012 | 2012 | 1 | 1 |
2 | 02/01/2012 | 2012 | 1 | 1 |
3 | 03/01/2012 | 2012 | 1 | 1 |
4 | 04/01/2012 | 2012 | 1 | 1 |
5 | 05/01/2012 | 2012 | 1 | 1 |
6 | 06/01/2012 | 2012 | 1 | 1 |
7 | 07/01/2012 | 2012 | 1 | 1 |
8 | 08/01/2012 | 2012 | 1 | 2 |
9 | 09/01/2012 | 2012 | 1 | 2 |
10 | 10/01/2012 | 2012 | 1 | 2 |
11 | 11/01/2012 | 2012 | 1 | 2 |
12 | 12/01/2012 | 2012 | 1 | 2 |
13 | 13/01/2012 | 2012 | 1 | 2 |
14 | 14/01/2012 | 2012 | 1 | 2 |
15 | 15/01/2012 | 2012 | 1 | 3 |
16 | 16/01/2012 | 2012 | 1 | 3 |
17 | 17/01/2012 | 2012 | 1 | 3 |
18 | 18/01/2012 | 2012 | 1 | 3 |
19 | 19/01/2012 | 2012 | 1 | 3 |
20 | 20/01/2012 | 2012 | 1 | 3 |
21 | 21/01/2012 | 2012 | 1 | 3 |
22 | 22/01/2012 | 2012 | 1 | 4 |
23 | 23/01/2012 | 2012 | 1 | 4 |
I think this condition can be used:
date <= WeekStart(today(),-8)
Regards,
Michael