• 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.

Populate a stream of values based on multiple date conditions

Ankit1234

New Member
Hi everyone,

I am a new member of this forum and seeking help from anyone willing to offer.
I have some dates which change based on input cells (number of months). I have used edate to populate next date. From each starting date and continuing for the number of months mentioned against it, there is a rate. I want to populate a stream of amounts which takes rate based on date in the table and multiples it with area mentioned in cell E2.
Thanks
Screenshot 2022-04-19 133522.png
 
Well, I can shorten that formula in cell I3:
Code:
=IF(AND($H3>=$B$6,$H3<$B$7),$E$6,IF(AND($H3>=$B$7,$H3<$B$8),$E$7,IF(AND($H3>=$B$8,$H3<$B$9),$E$8,IF(AND($H3>=$B$9,$H3<$B$10),$E$9,IF(AND($H3>=$B$10,$H3<$B$11),$E$10,IF(AND($H3>=$B$11,$H3<$B$12),$E$11,IF(AND($H3>=$B$12,$H3<$B$13),$E$12,IF(AND($H3>=$B$13,$H3<$B$14),$E$13,IF(AND($H3>=$B$14,$H3<$B$15),$E$14,IF(AND($H3>=$B$15,$H3<$B$16),$E$15,IF(AND($H3>=$B$16,$H3<$B$17),$E$16,IF(AND($H3>=$B$17,$H3<$B$18),$E$17,IF(AND($H3>=$B$18,$H3<$B$19),$E$18,IF(AND($H3>=$B$19,$H3<$B$20),$E$19,IF(AND($H3>=$B$20,$H3<$B$21),$E$20,0)))))))))))))))*$D$2/12
to:
Code:
=INDEX($E$6:$E$20,MATCH(H3,$B$6:$B$20))*$D$2/12
Copy down.
 
Thanks a lot, this worked. Just to understand, how is match giving the result (row number ) when exact date is not found in column B.
 
Back
Top