Help with IF

  • Thread starter Thread starter Little Master
  • Start date Start date
L

Little Master

Once again Hi to all of u.


A1 contains date of purchase b1 contains date of sale & C1 contains the
status.
For eg. If i purchase a scrip on 9 Oct 2005 & sell it on the same date
the C2 shows status as "Intraday" ,similarly if i Purchase a scrip on
9 Oct 2005 & sell it on 12 Oct 2005 the C column shows the status as
"Sold".But if i buy a scrip on 9 Oct 2005 & sells it on 10 Oct 2005 the
C column shows the status "Intraday".Similarly if I buy a scrip on 09
Oct 2005 & dont sell till present date the C column shows "Holding".

For Eg.

A B C
9th Oct 9th Oct Intraday
9th Oct 10th Oct Intraday
9th Oct 12th Oct Sold
9th Oct Holding
 
How long to judge if it's 'intraday'?

Does this help?
=IF(NOT(ISBLANK(B1)),IF(B1-A1>2,"sold","itraday"),"holding")

the formula means:
If blank is B1 = holding
If B1-A1 > 2 = sold
If B1-A1 <= 2 = itraday
 
Back
Top