Nested IF formula

REE13

New Member
Joined
Nov 13, 2018
Messages
10
1
A
B
2
3
Date fie Reviewed
11/30/2018
4
First Date of Item Entry
12/15/2014
5
Last Stock Date
9/18/2016
6
Final Inv. Date
11/30/2014
7
Weeks on Promo Disp.
90.43

<tbody>
</tbody>

I am trying to figure out a way to turn this into an automatic spreadsheet/calculator function and am failing. I want to automate the "B7" cell.

I recreated best I could showing the follow parameters:


1. Date of First Item received (B4)
2. Date it was removed from shelf (B5) *note there needs to be the flexibility to have this column be blank if it's still on shelf
3. If the date it was removed (B5) was before final invoicing date (B6) than it's note relevant to what I am doing and can be marked "NA"
4. If item is still on shelf and B5 is going to be blank than date filed reviewed B3 will be used to calculate the # of weeks on display.


I tried this:


=IF(B5<b6),"na",if(b4>B6,AND(B5<1),(B3-B4)/7)),IF(B4>B6,AND(B5>1),(B5-B4)/7))


Didn't work at all...



I have tried many different iterations of the above (using IF, AND, and OR) and I can't do it..... ideas?

If you can follow the logic, I am trying to get weeks on the shelf.

Asking from today to Date first Received (# of weeks on the shelf)
Also - If removed early (B5) from date received to date removed BUT
If received before B6.. not interested.

Any help. Thanks!</b6),"na",if(b4>
 
Re: I need a nested IF formula (help)

Yes, B4 would be the date the item is placed on the shelf. Thank you for asking that clarifying question.
 
Upvote 0

Excel Facts

How to total the visible cells?
From the first blank cell below a filtered data set, press Alt+=. Instead of SUM, you will get SUBTOTAL(9,)
Re: I need a nested IF formula (help)

Okay.

Now, we are dealing with 2 different attributes of an item.

1. No of weeks the item is on display.
2. Whether the item had been accounted for during the last review.

2 different attributes can be displayed in 2 cells. No of weeks of display with the DATEDIF formula in B7. Whether accounted for during the last review in another cell, say B8, using my earlier formula, modified a bit.
=IF(B4 > B3,"NEW","ACCOUNTED") or =IF(B4 > B3,"NEW","")

Both these can be displayed on cell B7 using the following formula, however it may strip off the numerical property of the display and complicate further numerical operations based on the number of weeks on display!

=IF(B4 > B3,"NEW","ACCOUNTED")&" "&DATEDIF(B6,IF(B5="",B3,B5),"d")/7

or

=TRIM(IF(B4 > B3,"NEW","")&" "&DATEDIF(B6,IF(B5="",B3,B5),"d")/7)
 
Upvote 0
Re: I need a nested IF formula (help)

Hi Rachel,

Word
should be totally banned from this planet ...!!! :oops:

(Unless, you are typing letters the whole day long ...)

Please stick to Excel ...

You will make your life so much easier ...

As an example, the problem you have to solve ....

can ONLY be solved with Excel ... !!! :)

Take Care
 
Upvote 0
Re: I need a nested IF formula (help)

If we want to clarify your rules, let's deal with the First date and then with the End date ...

A. First date :

This start date can be B4 or B5 or B6 ...

What are the rules for this specific portion ?

B. End date

This end date can be B3 or B4 or B5 ...

What are the rules for this specific portion ?

Hope this clarifies
 
Upvote 0
Re: I need a nested IF formula (help)

Based on your Word table ... which is structured totally differently ...

For cell F2 ...
Code:
=DATEDIF(IF(C2 < E2,E2,C2),IF(D2="",B2,D2),"d")/7
<e2,e2,c2),if(d2="",b2,d2),"d") 7[="" code]

HTH</e2,e2,c2),if(d2="",b2,d2),"d")>
 
Last edited:
Upvote 0
Re: I need a nested IF formula (help)

Thank you. Sorry for the offensive word.. used so I could add an explanatory paragraph (thinking now I could have just merged a cell, lol. Also different table as I figured it would be more self explanatory if I laid it out in a much easier to grasp manner as actual example just seemed confusing.. so "dummy" table created for ease of answer.
 
Upvote 0
Re: I need a nested IF formula (help)

Hello,

Should the formula posted in message # 15 not produce your expected result ...

Please take the time to review the message # 14 ... in order to come up with clear rules for both your dates ...:wink:
 
Upvote 0

Forum statistics

Threads
1,214,985
Messages
6,122,605
Members
449,089
Latest member
Motoracer88

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top