Welcome to Sign in | Help

Comparari date calendaristice

  •  10-25-2010, 9:45 PM

    Comparari date calendaristice

    Buna seara,

    as avea si eu o intrebare.
    Lucrez cu sql server 2005. Am de realizat un Raport in Reporting Services (un matrix):
    An/Luna/Saptamana/Zi an curent - An/Luna/Saptamana/Zi  anul trecut.

    Cu ajutorul unui Assambly  - sincronizez: Luni a.c. cu Luni anul trecut (Luni 18.Oct.2010 Vanzari:10 000 - Luni 19.Oct.2009 Vanzari: 9 200)

      A.C.                           A.T.                        Vanzari
    Vineri 01.10.2010       Vineri 02.10.2010         5 000 (a.c)
    Luni    04.10.2010       Luni   03.10.2010         6 200 (a.c)
    ...                                    ...                            ...
    ...                                    ...                            ...
    ...                                    ...                            ...
    Luni 19.10.2010          Luni 18.10.2009          6 900 (a.c)
    Marti 20.10.2010        Marti19.10.2009          9 000 (a.c)

    Problma este:
    trebuie sa compar Luna a.c. cu Luna a.t.
    ParallelPeriod (mdx) nu functioneaza, deoarece am o sincronizare de zile.
    Pe intelesul tuturor:

    A.C.                           A.T.                          Vanzari
                                    Joi      01.10.2010       6 100 <- aceasta pozitie imi lipseste din raport. Numai asa pot compara Oct.2010 cu Oct.2009
    Vineri 01.10.2010       Vineri 02.10.2010         5 000 (a.c)
    Luni    04.10.2010       Luni   03.10.2010         6 200 (a.c)
    ...                                    ...                            ...
    ...                                    ...                            ...
    ...                                    ...                            ...
    Luni 19.10.2010          Luni 18.10.2009          6 900 (a.c)
    Marti 20.10.2010        Marti19.10.2009          9 000 (a.c)




    Are cineva vreo Idee cum as putea rezolva aceasta prolema cu ajutorulu unui script MDX?
    Sau o alta idee?

    Va multumesc anticipat
    Ysa


View Complete Thread
Powered by Community Server (Commercial Edition), by Telligent Systems