• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

How to pick a value based on dates and item code

Hussainm

New Member
Hello everyone needed your help regarding one formula.


Basically we are selling three products, and for all three products the margins change almost every 10 days. Now I need to make a formula that would first check the product id (1,2,3) and then the transaction date and pick the corresponding margin. The margin change is applicable from the date it changes


Hussain
 
Hi Hussain,


Just wanted to confirm that the data from B2 to G4 are the margins which you want to fetch for the products(ID 1,2,3)on certain dates right!


If my understanding is correct, the here is the formula base formula at Col E starts from E8 (and drag it down):


=SUMPRODUCT(($B$1:$G$1=$B8)*($A$2:$A$4=$C8)*($B$2:$G$4))


I just see there are lot of dates which do not match with dates listed from B1 to G1. For those cases formula will return blank at Col E.


Please let us know if this is fine or I fail to understand your requirement correctly.


Here is the file:


http://speedy.sh/P29Tn/Margine-lookup-up.xlsx


Regards,

Kaushik
 
Back
Top