Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Can u please correct the formulae

Status
Not open for further replies.

rrbo

Programmer
Joined
May 7, 2003
Messages
24
Location
US
Dear All,

I have a field like “Month” , that contains the data base values 1,2,3,4……12.
But I want get those values according to sysdate. Like if sysdate is the month 5 then ,I should have to filter the values for Month field is 5, 4,3 .

I created a varible M1(reploaced in the field Month) and in that used formula like
=<Month of Dest Date> InList (MonthNumberOfYear(CurrentDate())-2,MonthNumberOfYear(CurrentDate())-1,MonthNumberOfYear(CurrentDate()))

But I am unable to filter according my problem. When I use the above formula, the field values are showing in the report as same as the formula.

Can any body correct the formula to achieve my result.

My data base is Oracle.

Thanks
rrbo
 
Dear Steve,

Please give me your e-mail Id , i can send my report for your verification


Thanks
rrbo
 
Build a derived filter:

Format Filter -> Add

Add the filter on <Month of Dest Date>. Press Define. Add the formula :
=<Month of Dest Date> Between ((MonthNumberOfYear(CurrentDate()) - 2) , MonthNumberOfYear(CurrentDate()))

Steve Krandel
BASE Consulting Group
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top