VLOOKUP With Two Match Requirements
Dec 23, 2008
In Column A I have vessel departure dates
In Column B I have Final Destinations
In Column D I have vessel arrival dates
I am trying to get the result of column D based on matching A & B information. My dilemma is that if I have vessels with the same departure dates going to different destinations how can I retrieve the arrival date? I've been trying "vlookup" and "index/match" to no avail.
View 4 Replies
ADVERTISEMENT
Mar 11, 2014
I am having some trouble getting a formula to work. I am building a report that pulls figures from a pivot table in another workbook. I am using a vlookup with match function to get the column index to find the relevant data I want. Where I need to add two columns together I am using sum, with the vlookup & match formulas nested in them e.g.:
=SUM(VLOOKUP(F13,'[PIVOT 156.xlsx]PIVOT'!$C:$AQ,MATCH("FAID",'[PIVOT 156.xlsx]PIVOT'!$C$6:$AQ$6,0),FALSE),VLOOKUP(F13,'[PIVOT 156.xlsx]PIVOT'!$C:$AQ,MATCH("COMM",'[PIVOT 156.xlsx]PIVOT'!$C$6:$AQ$6,0),FALSE),VLOOKUP(F13,'[PIVOT 156.xlsx]PIVOT'!$C:$AQ,MATCH("BPCM",'[PIVOT 156.xlsx]PIVOT'!$C$6:$AQ$6,0),FALSE),VLOOKUP(F13,'[PIVOT 156.xlsx]PIVOT'!$C:$AQ,MATCH("COMD",'[PIVOT 156.xlsx]PIVOT'!$C$6:$AQ$6,0),FALSE))
Where:
F13 = Employee number
Column C on the pivot 156 workbook is where the employee number is based.
The Match formula is then getting the column index from the column headings of the pivot table ie. "FAID"
This in itself works fine, as long as it finds a match in the column headings. This is where i get the error as in the above function "COMD" is not in the pivot table. However I need to keep it included as it may appear on a future pivot table. Is there a way of getting the sum function to complete even though later in the formula it can't complete the vlookup? So it will ignore it, or assume the value is zero if it can't find it? The formula probably needs to do this for all the vlookups as some headings may drop off in future pivot tables.
View 2 Replies
View Related
Oct 8, 2009
I am trying to match data from 2 independent sets, formatted slightly differently so not sure which function would work best for me. From the attached file, I am trying to match the date and time stamp (in cell A1) with that from the other data (in this example in cell E1) and return the data (from cell F1) to cell C1. So basically any date and time stamp before 04/03/09 04:00 will return a value of 44 (this value should appear, therefore in cells C1 - C30)
View 2 Replies
View Related
Feb 4, 2014
I have two sheets of data , sheet A and Sheet B.
Sheet B contains a column called "Name" and for each name, and for each name there are corresponding numbers. In sheet A, I have a "list of interest" in column A. What i want to do look through the data in sheetB to find a match from the list of interest and return the corresponding letters, located in column A.
I have filled out the first two rows of results that should be returned as an example.
One idea i had was to put a vlookup formula in each column result 1 to result 6 so i can catch all 6 "Serves" columns from column B, but there may be duplicates in the serve columns and vlookup only reports the first match.
View 3 Replies
View Related
Oct 19, 2009
Need to summing a column if it meets two requirements. First it has to be (column A)type1 A and (column B)type2 W. if type1 and type2 are true, sum column C. I also attached a file that explains what i'm looking for.
View 5 Replies
View Related
Aug 6, 2012
The logic is that I want the cells to be highlighted and have a border drawn for them as shown in the attached sheets (I have used record macro which will do this for rows 39 and 40 when the click button is clicked). The highlighting should start at the row number specified, stop once a merged cell is reached, skip the merged cell, continue highlighting, stop once a merged cell is reached, skip the merged cell, continue highlighting and so on and on until the last row (which is user specified) is reached. The first row after the merge cells should be highlighted in grey and yellow.
View 9 Replies
View Related
Jan 5, 2014
What is my requirements in the attached snapshot and excel file .
Please check the attachment. Charts.JPG
View 1 Replies
View Related
Feb 5, 2010
I've been asked to produce a spreadsheet that monitors the time it takes to answer queries from partner companies. Ive attached some of the spread sheet that im struggling to work out. I would like a formula that will total the number of days it takes us to answer the queries per month for each company.
Example - For January
Compnay A 8 Days
Company B 7 Days
Company C 13 Days
View 3 Replies
View Related
Nov 11, 2009
I have a database where I need to count the qty of such item but it has to comply with two requirements. It will count only those that are similar to one of the cells but if the number is the same, not taking in count.
Example:
ItemLiablibity354A354A543A345A567A456B567B
So, I want to count all the items but only the one that matches the A on the column "Liability" but if it is repeated, not counted.
so the resul must be: 4 as one number is repeated.
View 9 Replies
View Related
Aug 30, 2013
I would like a cell to show either OK or No depending on the requirements of three other cells as below
G4 is the cell to show a value. For OK a date in G6 must be more than todays date, a tick must be in F6 and a date in D6 must also be more than todays date.
I can get G4 to do each section individually i.e. (A4 has todays date in it, updating automaticaly)
=IF((G6+365)
View 2 Replies
View Related
Nov 17, 2007
I have drawn up a simple summary to show what I am trying to achieve: ...
View 9 Replies
View Related
Jun 30, 2006
I am trying to create a macro that will copy data from one sheet to four other sheets depending on some requirments in the data. I have a main worksheet that will store the data, the name on this sheet will change daily, so you cannot use a "named" sheet in your macro. The other three names of the sheets are "Esky", "Indy", "Gfld", and "Other". When copying the data, I need to copy the entire row of data to the required sheet. The data comes in such as:
MZ03948 134 126.23
PZ34533 128 12.28
IM04985 630 198.50
Z109384 40 35.65
2130494 76 12.28
2236326 12 45.63
5123132 12 12.23
Based on the FIRST TWO characters in the first column, I need to copy the data to the specific sheet. I would assume a simple LEFT() function would work for this. Here are the requirments for each sheet:
Esky - "MZ" or "51"
Indy - "IZ" or "Z" or "21"
Gfld - "PZ" or "22"
Other - Anything else
View 9 Replies
View Related
Oct 8, 2009
I have this table
.......A.....B.....C....D
1.....I......a.....d.....g
2.....II.....b.....e.....h
3.....III....c.....f......i
As you can see, the number I has a,d,and g, II has b,e,and h, and III has c, f, and i
I want to make formula that if I make the input g it would return I, f would return III, and c would return III, and so on
I want to make four formulas by using VLOOKUP, INDEX, MATCH, INDEX&MATCH separately.
View 9 Replies
View Related
Dec 29, 2013
With VBA in Excel 2010 I am connecting to a SQL server by using ODBC.
This is a two part process:
Part one:I have created a connection string that gets me the following data: A, B, C, D, E from sheet tpoPurchOrder Where B is equal to "1" And Where C is equal to a changing field under Sheets("Macros").Range("B2")
Here is part one
Code:
Sub Part1()
Sheets("Open PO by Vendor").Select
Sheets("Open PO by Vendor").Cells.Clear
With ActiveSheet.ListObjects.Add(SourceType:=0, Source:= _
"ODBC;DSN=Connection;Description=Description;UID=USER;PWD=PASSWORD;APP=Microsoft Office 2010;WSID=Workstation;DATABASE=Database" _
, Destination:=Range("$A$1")).QueryTable
[code]...
Part one works perfectly.
Part two is where I have problems.Part two is a little different because I have the same connection, but what changes is the table that I am looking at "tpoPOLine" instead of "tpoPurchOrder" and the where is now going to have a variable number of commands.
I want part two to be depend on part one. Under part one I want the result from column E to be a where statement in part two.
As follows:
In particular: *E3 from Part 1*, etc.
Code:
"SELECT tpoPOLine.Status, tpoPOLine.POKey, tpoPOLine.ItemKey, tpoPOLine.POLineNo, tpoPOLine.UnitCost, tpoPOLine.ExtAmt" & Chr(13) & "" & Chr(10) & "FROM mas500_DII_app.dbo.tpoPOLine tpoPOLine" & Chr(13) & "" & Chr(10) & "WHERE (tpoPOLine.POKey=*E2 from Part 1*) OR (" _
, _
"tpoPOLine.POKey=*E3 from Part 1* ) OR (tpoPOLine.POKey=*E4 from Part 1*)" & Chr(13) & "" & Chr(10) & "ORDER BY tpoPOLine.POKey" _
)
Now my problem is that sometimes the E column from part one ends up being 1 row, sometimes it ends up being 50 rows. I would like the code to change accordingly.
1. Pull everything from the SQL server filter once in excel. This is not as efficient as the database has ~300,000 rows in the tpoPOline table and would take a lot longer then needed.
2. Create a nested if table and
Change
Code:
WHERE (tpoPOLine.POKey=*E2 from Part 1*) OR (tpoPOLine.POKey=*E3 from Part 1* ) OR (tpoPOLine.POKey=*E4 from Part 1*)"
to the value of that nested if table
The nested if table would be something like =if(isblank(E2),"E1",if(isblank(E3)... etc for ~50 rows. I know the syntax is incorrect but you get my point.
3. Rerun the query for each value in column E. That would require the connection to happen ~50 times which would not be that great, as well as I would have to copy and paste the data after each run as the tables cannot overlap.
What I am looking for is a way to run this only once, on one sheet, without writing a nested if table with 50 if's.
View 5 Replies
View Related
Nov 20, 2007
I am either trying to do 2 vlookups or 1 match and a vlookup, but I am not sure. I have two workbooks. The first workbook I need to populate the 'Actual Taken' column from my second workbook. Below is the first workbook:
******** ******************** ************************************************************************>Microsoft Excel - FY07Q3_LMS_Payroll_.xls___Running: 11.0 : OS = Windows Windows 2000 (F)ile (E)dit (V)iew (I)nsert (O)ptions (T)ools (D)ata (W)indow (H)elp (A)boutD9=
ABCD1*Training*HoursStore*Manager*2Pay*Per*Hour*$28.37Actual*Taken3LMS*Courses4Baseball*/*Softball*Basics***5Baseball*/*Softball*Equipment***6Bike*Basics***7Bike*Fitting*and*Essential*Items***8Callaway*Golf***9Columbia*Footwear*Technologies*2006/2007***RCoursebyPosition_MGR*
[HtmlMaker 2.42] To see the formula in the cells just click on the cells hyperlink or click the Name box
PLEASE DO NOT QUOTE THIS TABLE IMAGE ON SAME PAGE! OTHEWISE, ERROR OF JavaScript OCCUR.
The second workbook contains all of the data. Please see below:
******** ******************** ************************************************************************>Microsoft Excel - Book2___Running: 11.0 : OS = Windows Windows 2000 (F)ile (E)dit (V)iew (I)nsert (O)ptions (T)ools (D)ata (W)indow (H)elp (A)boutA1=
ABCD462Softlines*MgrTeam*Sports*-*Hockey**Count3*463Softlines*MgrTeam*Sports*-*Lacrosse*Count2*464Softlines*MgrTeam*Sports*-*Soccer**Count4*465Softlines*MgrTennis*Audio*CD*Test*Count4*466Softlines*MgrTennis*Basics**Count7*467Softlines*MgrTennis*Equipment*and*Technologies**Count7*468Softlines*MgrUnder*
What I would like to do, is first have the formula locate the Store Manager from the First workbook and find it in the Second Workbook, then once it finds Store Manager, look at the Course Name from the Frist Workbook and find it in the second workbook, finally populate column C from Workbook 2 to the Actual Taken in Workbook 1.
View 9 Replies
View Related
Mar 20, 2007
I have an account issue. In the attached file sheet Balance, there is a trial balance sheet with account ID, Name, Credit and Debt which I download from system every month. In sheet Check, I have some related account IDs. If the ID is found from Balance sheet and is Credit, the amount in Check sheet will be positive. Otherwise it will be negative.I have ever tried to use Match, Vlookup function to do it but did not get it.
View 3 Replies
View Related
Jul 24, 2014
Why I am getting N/A errors in sheet 1 of workbook?
For example, in sheet1, Cell B2 should equal 3. And it should stretch across the entire data range, so even something like B14 should return 3.
View 8 Replies
View Related
Nov 26, 2008
I have a spread sheet of information exported from an inhouse software package saved to my computer; this info is a few months old so i want to compare it against newly exported data to check for new companys on the system and changes of address for old companies etc.
Typical fields are as follows:
Setting name; street address; post code; etc...
View 5 Replies
View Related
Oct 22, 2009
I have a worksheet that has numerical data in A1:A22. In E1:E61 I have set values in numerical order and in F1:F61 I have a letter or letters that correspond to E1:61.
I am trying to write a formula in B1 that will look at the value in A1 and then match it up in E1:E61 and then return the corresponding letter in F1:F61.
e.g: in A1 i have an INDEX and MATCH formula
View 2 Replies
View Related
Nov 13, 2009
In cells A1:A10 I have the following list;
FLOUR
DOUGH
CHICKEN
BEEF
PEPPERS
TOMATOES
CHEESE
ONIONS
POTATOES
SALAMI
I want to be able to get a partial match that will allow for spelling mistakes by the user. The wild card (*) seems to only look at the left-most text and return #N/A if the text isn't matched sequencially.
For example ....
View 12 Replies
View Related
Aug 26, 2007
i have a customer work book for outstanding orders of which there are hunderds of rows with there name order number and the items that are outstanding
when i have progressed all my purchased orders i take all the items and run it throught my work book using vlookup to return who wanted what items if any
but what if there are more then one customer wanting the same item how can i get vlookup to know that and return the next match
i'm still very new at excel so can someone please help me
attached is a small test of my work book
if you see item 3182Y/1.0/BLK
you can see it is wanted by both a.f switchgear and amg
but it will only return a.f switchgear
View 14 Replies
View Related
Sep 23, 2008
I have two columns with names on it. and Column A has about 600 names and column B has about 447 names. I want to match these two columns and get the names which do not match on Column C.
View 11 Replies
View Related
Nov 19, 2008
i currently have a spreadsheet that uses vlookup and match to identify data that matches 2 criteria.
so there is a table with names on the left and dates on the top, and the dates change over time. this reference another table with the data for the names at all dates. therefore, the formula does is a vlookup with a match inside it.
this works well.
so say today is Jan 1.
Columns 1, 2 and 3 are Jan 1, Feb 1, March 1
On Feb 1, columns 1, 2, and 3 are Feb 1, March 1, April 1
in column 4, i want it to equal the sum of the data for all dates beyond the date in column 3.
does this make sense?
i attached a small sheet i was working on to play around with these functions. in the sheet i just used numbers (1,2,3) instead of the dates for simplicity
View 4 Replies
View Related
Dec 2, 2008
I have a spreadsheet that looks like this:
ABCD E F
1Scenario A Scenario BScenario C
2Studio1520
31Bed1520
42Bed150
5
6
7Scenario A Scenario B Scenario C
8Studio5% 10% 15%
91Bed10% 15% 20%
102Bed15% 20% 25%
RIght now my formula For Cell D2 is
=IF(C2=0,(B2*-$D$8),0)
I need the formula to Match what is in Column A and Also what is in Row 1 to what is in the table (C7:F10)
View 3 Replies
View Related
Aug 17, 2009
I am able to to use the Vlookup to look up for value in the "Sheet sept". All value can be updated expect the item called "mug" as it is not listed in the "Sheet all". How do I highlight the missing item in the "Sheet all"? Attached herewith a file for better understanding.
View 11 Replies
View Related
Sep 21, 2002
How do you do a vlookup with a partial match?
View 5 Replies
View Related
Oct 30, 2012
I am having 2 workbook. I want to vlokkup / extract the relevant column values if Lookup_value DOES NOT MATCH.
Ex:
Workbook1
A1=PPP-00099
Workbook2
C1=PPP-00088 E1=786
In F1 (of Workbook2), answer would be 786 since C1 DOES NOT MATCH with A1.
If matched, answer required="" (null).
View 5 Replies
View Related
Dec 15, 2006
I am using Vlookup to search for a text string in column A and storing the value of column B for more than 40 variables.
I do NOT want a macro error on Vlookup each time it can not find a match. I want to store an "error message" in that variable and move on.
countif and a rountine handler sounds like a lot of coding for each variable; can I use ISNA?
SAMPLE
Sheets("CPARS download").Select 'CPARS DOWNLOAD
RFQnum = Strings.Mid(WorksheetFunction.VLookup("RFQ Number", _
Range("CPARSdata"), 2, 0), 1, 13) 'RFQ# should be same for each supplier
' RFQnum = Mid(RFQnum, 1, 13) 'truncate the supplier code at the end
BidDue = WorksheetFunction.VLookup("Bid Due Date", Range("CPARSdata"), 2, 0)...........
View 9 Replies
View Related
Apr 20, 2007
Here's a sample data set. How can i perform a vlookup to populate my forecast columns and have it match BOTH the customer column and the SPFKey columns?
******** ******************** ************************************************************************>Microsoft Excel - Receiving Qtr1 2007.xls___Running: 11.0 : OS = Windows XP (F)ile (E)dit (V)iew (I)nsert (O)ptions (T)ools (D)ata (W)indow (H)elp (A)boutL20=
ABCDEFGHIJKL1Business*UnitCustomerSPF_KeyFORECASTACTUALS*2"NBPRO"Sold-to*PartySPF_KeyJanFebMarTtlJanFebMarTtlVariance3NBPROAAR*CORP.883***01*1224NBPROAAR*CORP.933***020**20205NBPROAAR*CORP.934***09**996NBPROAAR*CORP.999***02*1337NBPROAEROTHRUST*CORPORATION6600***01**118NBPROAIR*CHINA*IMPORT*&*EXPORT*CO.*LTD918***0*11229NBPROAIR*CHINA*IMPORT*&*EXPORT*CO.*LTD919***0*112210NBPROAIR*CHINA*IMPORT*&*EXPORT*CO.*LTD933***042422210610611NBPROAIR*CHINA*IMPORT*&*EXPORT*CO.*LTD934***042424112512512NBPROAIR*CHINA*IMPORT*&*EXPORT*CO.*LTD1742***0*1*1113NBPROAIR*CHINA*IMPORT*&*EXPORT*CO.*LTD1793***0*0*0014NBPROAIR*CHINA*IMPORT*&*EXPORT*CO.*LTD1795***01**1115NBPROAIR*INDIA933***036408215815816NBPROAIR*INDIA934***046176512812817NBPROAIR*INDIA1742***0**00018NBPROAIR*INDIA6601***0*1*1119NBPROAIR*INDIA6602***0*1*1120NBPROAIR*INDIA6603***0*0*00Sheet2*
[HtmlMaker 2.42] To see the formula in the cells just click on the cells hyperlink or click the Name box
PLEASE DO NOT QUOTE THIS TABLE IMAGE ON SAME PAGE! OTHEWISE, ERROR OF JavaScript OCCUR.
View 9 Replies
View Related
Apr 3, 2008
I have two worksheets that I am hoping to use to generate one report in excel. Sheet1 contains the following information for my entire work center:
Benefitor Account Dollar Value Document #
Sheet2 contains a list of Benefitors that are relevant to only me.
I want to pull the information from Sheet1 where the benefitors on Sheet1 match the benefitors listed on Sheet2 into Sheet3.
View 11 Replies
View Related