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

Inventory Last Active Date Calculation with empty date values

Status
Not open for further replies.

MBGuidry

Technical User
Dec 5, 2011
7
0
0
US
Can someone please help me? I am running a crystal XI report showing what the inventory turnover is, and the timeline. I have a column with "Last Sold Date" and another with "last receipt date". I built a formula to show the last active date (shown below).

If{CI_Item.LastReceiptDate}<{CI_Item.LastSoldDate} then
{CI_Item.LastSoldDate}else
{CI_Item.LastReceiptDate}

The formula works, but nothing is returned when there is an empty sold date or an empty last receipt date. How do I write the formula so that If the "last sold date" is empty it returns the "last receipt date" and vice versa?

Example of my data:
Item LastSoldDate LastReceiptDate LastActiveDate

xxx Apr-11 Jul-10 Apr-11
xxx Jul-11



I need the formula to return the Last receipt date in the ex. above


any suggestions would be greatly appreciated!
 

When you say 'empty' - what do you mean?
Are the fields declared as Dates? Text? Do you have there an empty space? One space? Or NULL?

Have fun.

---- Andy
 
The fields are declared as dates, but there is no value assigned in the database for the "empty" date fields. No data was entered in the date for that inventory item. I am guessing this means a Null value.

I need the formula to give me back the last receipt date when the last sold date is null ( no value given).

Also - how do I access the Crystal Reports forum? I was not aware I could post my questions there.

Thank you all for your help. I truly appreciate any direction you can provide.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top