VLOOKUP / index+match / with multiple criteria

stopo

New Member
Joined
Jan 14, 2020
Messages
6
Office Version
  1. 2019
Platform
  1. Windows
Hi

Im very beginner with excel. I got a task with need help. I read forums now several days but I cannt got any solution yet. Try Vlookup index match formulas but always run into walls.

I need result for the B column. I already fill the B how it have to be look like and write the criteria into the excel too.
If a number appearence in A the first 2 is always X in B. Any more appearence in A will be Y in B until C<=D. / C is in Y row D is in the last row where X is. / If not the first 2 appearence start again.

I try this:

IFS(A1<>A0;"X";AND(A2=A1;A2<>A0);"X";AND(C2<=VLOOKUP(A2;A1:A1000;4;0));"Y";AND(C2>VLOOKUP(A2;A1:A1000;4;0));"X"

And this work for me until A1 first appearance period start again. Than the VLOOKUP dont work anymore because this give the first value in D. I try index , match , max , maxifs but cant
get any working well.

Sample excel.JPG

Thanks in advance If any help I can get.

Stopo
 
One more idea: you can save your data from Excel as a CSV file and post here as such. That's good enough. I need only the rows you did tests on.

J.Ty.
 
Upvote 0

Excel Facts

Easy bullets in Excel
If you have a numeric keypad, press Alt+7 on numeric keypad to type a bullet in Excel.
OK, I'll wait.

J.Ty.
I think I got it! I put ORANGE letters to it and it working now. Now I will test it with my 10000 rows sheet I hope it will be good. THX YOUR HELP again! I am very grateful!

=IFS(A3<>A2;"X";A3<>A1;"X";INDEX(D$1$:D2;MAX(($B$1:B2="X")*ROW($B$1:B2))-1)<C2;"X";AND(A3=A2;A3=A1;B2="X";B1<>"X");"X";TRUE();"Y")

Stopo
 
Upvote 0
I'll keep my fingers crossed!

J.Ty.
 
Upvote 0

Forum statistics

Threads
1,214,523
Messages
6,120,028
Members
448,940
Latest member
mdusw

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