Last Year Quater, Current quater

Hi All,

how to calculate current quater and prior quater volume. Please provide me the code. I have to create the object in universe and user want to view both current quater and last year quater in one report.

Thanks!!!


write2me (BOB member since 2007-08-12)

Are you talking about last 6 months or what?

What are you taking about?

Thanks,

Ranjan


ranjan.sahoo :india: (BOB member since 2007-06-11)

what database are you using ? And do you have any summary tables in your database ? It depends on how is your data stored in the database…

In oracle, you can get the current quarter start date and end date as follows:

Quarter Start Date:


=trunc(sysdate,'Q')

Quarter End Date:


=add_months(trunc(sysdate,'Q'),3)-1

In the same way, you have to check for the year and subtract 1 to get the previous year quarter.

Hope that gives you a start.


BO_Chief :us: (BOB member since 2004-06-06)

There is already a question on this here and it has more detail. Will close this one.

Please do not start a new topic for the same question, thanks.


Dave Rathbun :us: (BOB member since 2002-06-06)