Look Up value based on "X"

pratheesh1983

Board Regular
Joined
Aug 13, 2015
Messages
55
Office Version
  1. 365
Platform
  1. Windows
Hello

I have a spreadsheet like below used by a sales distributor:

In this sheet, 1st Column shows items the distributor sells. The next columns denotes the retail or supermarket group who buys items from the distributor. This sheet is maintained on daily basis, and if any supermarket or the retail guy buys any items then the distributor put a "X" in the column of the specific buyer and next to the item.


Items MG RetailA1 Super MarketEmpire StorePTK Retail
Rice XXX
Vegetable X
Tooth Paste XX
Detergents X X
Bed Sheets XX
Floor Cleaning LiquidX X
Water BottlesX
Spoon - Steel XX
Sun scream LotionXXXX


<colgroup><col><col><col><col><col></colgroup><tbody>
</tbody>

Requirements:

At EOD, distributor needs to convert the data from the above sheet in the below mentioned format which specify the item each buyer has brought on that particular day, and listed down just below to buyers name. So here I'm looking for a formula which will populate the item name below to the buyer name as soon as "X" is recorded in the data captured sheet. The buyer name and items will be always constant. Is there any excel formula which can help me this, please advice?

Thanks in advance!

Format

MG Retail


Vegetable
Floor Cleaning Liquid
Water Bottels
Sunscream Lotion






A1 Super Market


Rice
Tooth Paste
Detergents
Bed Sheets
Spoon - Steel
Sunscream Lotion




Empire Store


Rice
Tooth Paste
Bed Sheets
Spoon - Steel
Sunscream Lotion




PTK Retail


Rice
Detergents
Floor Cleaning Liquid
Sunscream Lotion
 

Excel Facts

Can Excel fill bagel flavors?
You can teach Excel a new custom list. Type the list in cells, File, Options, Advanced, Edit Custom Lists, Import, OK
How about this?

In F1
=IFERROR(INDEX($A$1:$E$10,AGGREGATE(15,6,ROW(B$1:B$10)/((B$1:B$10<>"")),ROWS(A$1:A1))-(1-1),IF(ROW()=1,COLUMN()-4,1)),"")
copy across and down as far as H10.

Your buyers are in columns rather than a single list, where only the selected items are listed.

If you want to paste the output to a different sheet / position remember to Paste Values rather than normal Copy/Paste.
 
Last edited:
Upvote 0
Thanks K99 - Had a question - If I have to place this formula in A11 cell, then what changes I need to make here?
 
Upvote 0
On the same sheet?
Try

=IFERROR(INDEX($A$1:$E$10,AGGREGATE(15,6,ROW(B$1:B$10)/((B$1:B$10<>"")),ROWS(A$1:A1))-(1-1),IF(ROW()=1,1,1)),"")
 
Upvote 0

Forum statistics

Threads
1,214,967
Messages
6,122,503
Members
449,090
Latest member
RandomExceller01

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