Using VLOOKUP across Spreadsheets. - excel

I have two spreadsheets. I'm trying to use VLOOKUP, but it simply is not being nice. The cell that's suppose to be updated does not.
-Spreadsheet A has indices that need to be paired with Spreadsheet B indices.
-Then I need to get the corresponding value to that indices. Those values are one cell to the right of the indices in Spreadsheet B.
-The value in Spreadsheet B then needs to be placed in its appropriate cell back in Spreadsheet A.
If someone could help that would be great and ... fabulous. If you need more details or clarification let me know. I have a feeling it might be my using of Table Name across spreadsheets as the culprit for it not working properly.

Try using and Index Match combo function
Index('Column/array with return value',MATCH('Value to match','Array to find the value',0-For an exact match),'column number of the Column/Array to look in')
I am not a fan of VLOOKUP as I almost always find errors with it. There are plenty of indexMatch examples too on here and Google.

Related

VLOOKUP Multiple Columns If Not Found In First Column

I have a long list of part numbers where I need to be able to lookup and retrieve information on them.
These parts can have several alternative part numbers. I have figured out how to get the data returned if my data table only shows one of the possibly part numbers.
The issue is that I want it to be able to look up the columns to find a matching value.
As in the picture below for example. 5-E26 is the equivalent to E5-25. So if I input 5-E26 in the cell, I want it to continue searching to find the value in B7, and return the data as done A4 and A5.
Is this possible to do with Vlookup? Or is there a smarter method for it?
I struggle to fully understand how your data works but here is a possibility:
So the translated version of the formula I used in G2:
=INDEX($D$1:$D$5,AGGREGATE(15,3,((($A$2:$D$5=F2)/($A$2:$D$5=F2))*ROW($A$2:$A$5)),1))
You could also try (in my case):
=INDEX($D$1:$D$5,SUMPRODUCT(($A$2:$D$5=F2)*ROW($A$2:$D$5)))

Vlookup function generating duplicate values, how can I fix this please?

Hy Every Body, I have two excel sheets name as "Blotter" and "Opportunity", I want to use "Vlookup" Function in Opportunity so that I can find out which opportunity is available in the blotter sheet. Please take a look at the Blotter sheet as under
In the Column B the Opportunities are available.
Now please look at the opportunity sheet.
In the opportunity sheet I am using this function.
=IF(D2 = "","",VLOOKUP(D2,blotter,10,0))
It working fine with first five rows but later it start duplicate the same value multiple time, because behind these cell on the blotter sheet the column B has Piad/place status instead of opportunity. So it duplicate the next opportunity. I have tried many tricks like match, index, but in vain.
I know it can be fixed. I have google it and also try to find it via youtube but unable to fix it.
I don't think it can be done without an intermediate column. The position of the next value in the lookup key depends on where the position of the last successful lookup was, so in a way the lookup chain is path dependent and I don't think you can build path dependency with any ease inside an Excel formula.
In the below example you get something akin to what I think you want by calculating how many spaces there are to the next valid lookup key in Column C, and then doing an Offset in column D. In column C I use an indirect which generates path dependency based on the sum of the cells above itself. You would need to apply similar principles to your example, should only need a single equivalent of my column C.
Formulas as follows:
Column C: =MATCH("OPP",INDIRECT("A"&SUM($C$1:C1)+2&":A50"),0)
Column D: =OFFSET($B$1,SUM($C$1:C2),0)

Lookup Job Code, return column header if cell has text

I'm looking for a little bit of help learning about how to use vlookup and iferror formulas together.
I am working as a licensing specialist within the insurance industry. My job requires that I frequently access more than a dozen spreadsheets that are emailed to us on a weekly basis from our clients. I am working to develop tools that allow us to consolidate that information on-demand to be able to run reports. I'm having no trouble using the VLookup function to pull data from various spreadsheets using an unique identifier. I do need some help, however, with a trickier formula.
I have put together a spreadsheet that allows me to put in the ID of the representative and it returns various bits of information, such as their name, license numbers, job codes, etc. Now I need to come up with a formula that takes the value returned in the job code field and searches another spreadsheet to return what training they are required to complete based on their job code. This spreadsheet is about 2000 rows, and is formatted with the training names spanning across the top row, job codes listed in column "A" and the word "yes" in each column that matches a training that the job code is required to take.
It looks like this: https://i.imgur.com/71COmfF.png
I need the formula in my reports spreadsheet to lookup the job code using VLookup and then return the column header if the cell has text.
The data will be loaded into this spreadsheet: https://i.imgur.com/2CyFURt.png
Here is the Vlookup formula I am using to get the job code:
=VLOOKUP(B3,'.\[Weekly_HR_Report_040615.xlsx]HR'!$A:$Q,10,FALSE)
How can I pair that same kind of formula with something like an IfError formula to return the column header if there is a "Yes" in the cell of the row that matches their job code?
I know that I can work through it as an array using VBA, but I would prefer to just place a formula in each cell so that I can pass this spreadsheet to another college when I move to a different role in the future and they won't struggle too much with adding to it.
Thanks for any help that you might be able to provide! I really appreciate it!
I would use INDEX and MATCH to cross reference and retrieve the titles where applicable:
=IF(INDEX('JobCode_Training.xlsx'!$A$1:$H$6,MATCH($H$5,'JobCode_Training.xlsx'!$A:$A,0),2)="Yes",INDEX('JobCode_Training.xlsx'!$A$1:$H$6,1,2),"")
=IF(INDEX('JobCode_Training.xlsx'!$A$1:$H$6,MATCH($H$5,'JobCode_Training.xlsx'!$A:$A,0),3)="Yes",INDEX('JobCode_Training.xlsx'!$A$1:$H$6,1,3),"")
=IF(INDEX('JobCode_Training.xlsx'!$A$1:$H$6,MATCH($H$5,'JobCode_Training.xlsx'!$A:$A,0),4)="Yes",INDEX('JobCode_Training.xlsx'!$A$1:$H$6,1,4),"")
etc.
I wasn't sure what your reference table is saved as, so you'll need to replace 'JobCode_Training.xlsx'! with whatever the correct path is.
Since you have multiple trainings that can apply to each jobcode, you'll either need to have multiple cells for the results, or you can concatenate them into one.
The following article from excelvlookuphelp.com answers your question I believe...
The Problem
You might be expecting that not all of your search values are going to return something from the search table. Instead of the formula returning #N/A you’d like the result to look different when your vlookup value isn’t found (either blank or an indicator to show that the value hasn’t been found or a zero if you’re wanting to do maths with the results).
The Solution
You can use the iferror function.
It works like this
= iferror (YourVlookupFormula, WhatToSayInsteadOf#N/A)
Here’s an example
=iferror(vlookup(D3,A:C,3,false), “No Value Found”)
Or if you would rather it was just blank then instead of having No Value Found, just have the two sets of inverted commas, like this
=iferror(vlookup(D3,A:C,3,false), “”)
source: excelvlookuphelp

Match and lookup to find price

I would be grateful if someone could help with the following.
I have a workbook (called passenger car comparison) that has a column of postcodes (B1) and then columns for different prices (C1:I1).
In a separate workbook (called Search Tool), I would like to display the post codes from B1 as a dropdown list, with the same row also displaying the prices from C1:I1 for that particular post code.
Would I need to use INDEX and MATCH or HLOOKUP? Confused!
There is a link to the spreadsheet here if my explanation isn't clear!
Many thanks in advance!
You can actually use both.
However, you should use VLOOKUP instead of HLOOKUP, because your data elements are in rows, not columns. This is the most direct approach (=VLOOKUP(DropDown,WholeTableFromBtoI,Line,FALSE) - the FALSE here avoids linear interpolation with your postcodes). You can get your line from the row 1 of both cells, using MATCH, if you want to get fancy, by =MATCH(Category,FirstLineOfTable,0).
And, If you intend to use MATCH straightforwardly, your better approach would be using OFFSET as well, as in =OFFSET(FirstCellOfTable,MATCH(PostCode,PostCodeRow,0),MATCH(Category,FirstLineOfTable,0). It's a probably not the most intuitive approach, but it works as well.
Hope that helps.

Removing blank entries from Excel data validation with dependant lists

I need help removing blank entries from an Excel data validation list.
I’ve looked at various solutions, but in my implementation I am using dependent lists to drive several VLOOKUP, so none of the solutions I have found seem to work. As an Excel novice it’s difficult to work out which path I should be heading down, so I’d be grateful to anyone that could help out.
If anyone feels like a challenge and wants to have a look, my sheet can be accessed at: https://www.dropbox.com/s/b7lxe9oagzdaniy/MRF_Dashboard_v0.6.1.1.xlsm?dl=a
For your New list, in Raw!DL2 use this array formula.
=IF(LEN(DL1),IFERROR(INDEX($A$2:$A$99, MATCH(0,IF($A$2:$A$99<>"",IF($DK$2:$DK$99="",COUNTIF(DL$1:DL1,$A$2:$A$99),1),1),0)),""),"")
Array formulas require Ctrl+Alt+Delete to finalize. Once entered correctly you can fill down to Raw!DL100. This array formula produces a list of the numbers from column A where column DK is blank.
Similarly, the array formula for Raw!DM2 would be:
=IF(LEN(DM1),IFERROR(INDEX($A$2:$A$999, MATCH(0,IF($A$2:$A$999<>"",IF($DK$2:$DK$999="Pending",COUNTIF(DM$1:DM1,$A$2:$A$999),1),1),0)),""),"")
Fill down as necessary.

Resources