Topic
5 replies Latest Post - ‏2013-01-22T18:50:41Z by DanielWagemann
SystemAdmin
SystemAdmin
15496 Posts
ACCEPTED ANSWER

Pinned topic days between orders

‏2013-01-22T15:04:01Z |
Hi

I want to make a report with three columen (Quantity (New Order), Quantity (Regular Order) and Quantity (Total Order)). If a Customer didn't ordered a product within 365 days from the last order, the Quantity of the Order should be under New Order and else in the Regular Order. At the moment I have no clue how i should do that in Report Studio. Any advice?

Thanks Manuel
Updated on 2013-01-22T18:50:41Z at 2013-01-22T18:50:41Z by DanielWagemann
  • DanielWagemann
    DanielWagemann
    411 Posts
    ACCEPTED ANSWER

    Re: days between orders

    ‏2013-01-22T15:18:26Z  in response to SystemAdmin
    What type of package are you using... relational, OLAP or DMR?

    Does the data source you are using support any type of lag or lead functionality?
    • SystemAdmin
      SystemAdmin
      15496 Posts
      ACCEPTED ANSWER

      Re: days between orders

      ‏2013-01-22T15:22:35Z  in response to DanielWagemann
      We are using DMR with Teradata. Cognos 8.4.1
      • DanielWagemann
        DanielWagemann
        411 Posts
        ACCEPTED ANSWER

        Re: days between orders

        ‏2013-01-22T15:26:40Z  in response to SystemAdmin
        So DMR woud allow you to use the dimensional lag or previous member to get the previous order date value. Try implementing one of those functions.... If you are still having problems, please post an example against the Samples GO Sales(analysis) package and I will see if I can help you further.
        • SystemAdmin
          SystemAdmin
          15496 Posts
          ACCEPTED ANSWER

          Re: days between orders

          ‏2013-01-22T17:11:14Z  in response to DanielWagemann
          Thanks for the help. I try a mix between running-difference and _days_between now and it looks as it would work out.
          • DanielWagemann
            DanielWagemann
            411 Posts
            ACCEPTED ANSWER

            Re: days between orders

            ‏2013-01-22T18:50:41Z  in response to SystemAdmin
            Both those are SQL conventions.... how are you getting to the previous record to see if the elapsed time is greater than 356?