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 biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Crystal Reports 2008, Oracle 11g - Capture datediff 2 days before and 2 days after

Status
Not open for further replies.

hmax

Programmer
Jan 22, 2012
60
US
I need to create a formula that captures the following:

{table.field} >= datediff({table.fieldA},{table.fieldB}) where the datediff result is a range of 2 days before and 2 days after.

Thanks,

hmax
 
Please clarify

datediff result is a range of 2 days before and 2 days after

Relative to what?

Please show same data and what you wnt to show in your formula

Ian
 
So, clearer requirements below:

Capture a case that was created 2 days prior to, or 2 days after, the first commission date (commission date is a site attribute string field that will be converted to a date)


{CaseTable.CreationDateField} is 2 days prior to the first datevalue({SiteAttributeTable.CommissionAttributeField})
or
{CaseTable.CreationDateField} is 2 days after the first datevalue({SiteAttributeTable.CommissionAttributeField})


Thanks, IanWaterman.
 
{CaseTable.CreationDateField} < date({SiteAttributeTable.CommissionAttributeField})-2 or
{CaseTable.CreationDateField} > date({SiteAttributeTable.CommissionAttributeField})+2

-LB
 
Thanks, lbass! I had a brain freeze. Going in too many directions at once! Bye.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top