View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Susan Susan is offline
external usenet poster
 
Posts: 271
Default Should I use VLOOKUP? IF? INDEX?

I have a column in a large spreadsheet called "warehouse". "Warehouse" (A2
thru A7500) can be one of 25 possible names (MOreturns, MOinv, MOjunk,
TXreturns, TX2returns, TXjunk, AZreturns, AZ2, etc.). I am inserting a column
(B) where I want the warehouse location to populate unless it is a "junk"
warehouse, i.e. if A2=MOreturns, B2=MO; if A3=TXreturns, B3=TX; if A4=AZjunk,
B4=blank...
I tried using INDEX to match a name list but since it's not a 1:1
relationship, I couldn't get it to work and for some reason my nested IF
function came back saying one of my values was the wrong data type (I
enclosed the text in " " so I'm not sure what the "wrong type" was).
Would a VLOOKUP function work best or a nested IF function? Please give an
example of the formula. Please be specific. Thanks!