Formula required

Philip Wong

New Member
Joined
Jul 13, 2006
Messages
26
Hi,

I have a table of data and I am looking to copy some of that data into a range of cells, depending on the whether the data matches one other cell.

e.g.

Type Price Quantity
Hammer A £2 300
Nails B £3 500
Screwdriver C £2.50 400




Hammer ? ? ?
Nails ? ? ?
Hammer ? ? ?


From the example above I am looking to have the question marks read the data from the table, with Hammer reading the same data but wanting to read it twice as there are two entries.

Cheers,
Phil
 

Excel Facts

How to change case of text in Excel?
Use =UPPER() for upper case, =LOWER() for lower case, and =PROPER() for proper case. PROPER won't capitalize second c in Mccartney

Peter_SSs

MrExcel MVP, Moderator
Joined
May 28, 2005
Messages
50,645
Office Version
  1. 365
Platform
  1. Windows
Phil

See if this is what you want. Formula in F8 (copied across and down):
=VLOOKUP($E8,$A$1:$D$4,COLUMNS($E8:F8),0)
Mr Excel.xls
ABCDEFGHI
1TypePriceQuantity
2HammerA2300
3NailsB3500
4ScrewdriverC2.50400
5
6
7
8HammerA2300
9NailsB3500
10HammerA2300
11
Vlookup
 

Forum statistics

Threads
1,141,626
Messages
5,707,483
Members
421,510
Latest member
haroonstr

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
Top