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

Writing a formula "Over60Days"

Status
Not open for further replies.

lmorgan

Technical User
Jul 31, 2001
19
0
0
US
Good evening all!

I'm trying to return records on a report from a date field (formatted as: 03/01/01) that are greater than 60 days past due.

I'm using Crystal v8.0 and there is a lovely feature in the select expert that will allow you to pull either Aged61to90days or Over90Days, but I'm unable to figure out a formula that will read the Mastertable.Notice_Date and return if it is greater than 60 days.

Any suggestions ?

Thanks so much!
Lisa
 
IIF({Mastertable.Notice_Date} = Is <=(PrintDate - 60), @Amount},0)
 
LFB - Thank you for responding.

I've tried this formula, but I'm getting an error message that points to the &quot;@Amount&quot; characters that indicates that a number, currency amount, boolean, date, time, datetime, or string is expected here.

Also, because I'm looking to pull records that are 60+ days past due I'm wondering if the formula shouldn't reference as follows:

Code:
 IIF ({Mastertable.Notice_Date} = IS >(PrintDate + 60),@Amount,0)

which shows that I'm looking for results that are greater than the print date plus 60 days. Does this make sense?

The &quot;@Amount&quot; should actually return the Notice Date and not return a record if it doesn't fit the criteria.

I'm not a programmer (although I'm learning more every day!), so I'm hoping that I sound like I'm making sense.

Any thoughts?
Thanks!
Lisa
 
If you only want to SELECT records that are over 60 use the following in Report - Edit selection formula - record:

{Mastertable.Notice_Date} <= CurrentDate - 60

If you are selecting more records but tyring to TOTAL records in the report that are over 60 you can insert a formula field that uses:

If {Mastertable.Notice_Date} <= CurrentDate - 60
then <your amount field>
else 0

and create totals of this formula. Ken Hamady, On-site Custom Crystal Reports Training & Consulting
Public classes and individual training.
Guide to using Crystal in VB
tek@kenhamady.com
 
Have you tried using a simple

{date} in Aged61to90days
or
{date} in Over90Days

I use this myself in the selection formula and it works fine
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top