Combine oracle queries in universe

TO_CHAR(ADD_MONTHS(,-1),‘MM’)

TO_CHAR(ADD_MONTHS(,1),‘MM’)

How can I combine 2 queries in the universe …for one of the objects I need to use both the queries…in my application if user selects March month I need to show even previous months Jnuary , feb and also april, june,july.

Thanks
Sravanthi


sravyr (BOB member since 2010-05-04)

I think you are on the right trail already.

If you prompt them for the month, you can create a condition that uses the same prompt in the other parts of the condition:


TO_CHAR(ADD_MONTHS(<date>,-1),'MM') OR
TO_CHAR(ADD_MONTHS(<date>,-2),'MM') 

I guess this works as long as you know how many months you want to go backwards from on that one prompt.

V


Eric Vallo :us: (BOB member since 2002-08-15)