# Matching Data 2 Cells In 2 Sheets

Jul 10, 2014

is it possible to provide a formula to match as per the uploaded file. Data in Sheet one columns A and B, compared to what is in Sheet two column A I have a lot of data, and only need a Y for yes, and N for No as a result.

## Matching Data From 2 Sheets

Sep 19, 2012

I am trying to combine the data in two sheets.

In Row A sheet one, I have "name" In Row A sheet two, I also have "name"

If row A sheet two matches the data in row A sheet one, I want the corresponding data in row D sheet two to move to row E sheet one.

## Find And Replace Matching Cells Across Multiple Sheets

Dec 11, 2013

Following Excel task I am trying to complete:

I have an Excel file with multiple sheets and I want to find and replace matching cell data on the same row across all of the sheets. For example, I have two columns, Column A and Column C and 10 sheets. I want to only replace the content in Column A if text matches both Column A and Column C on the same row. So, I want to be able to search for the following data across all sheets:

Column A = "car"
Column C = "yellow"

If both "car" and "yellow" are found in Column A and Column C on the same row, then replace "car" in Column A with "truck".

Is there a way to do this automatically as I have few hundred to find and replace?

## Matching Cells Across Sheets And Returning Color Value Based On The Sheet?

Dec 24, 2013

I have a set of sheets on a workbook that contain addresses, which are all combined on the first sheet (as you can see in the attached file). I would like to use a formula to compare the addresses on the Main sheet with the other sheets, then return in the D column of Main a colored cell indicating on which sheet the address was found on; different colors for different sheets. I tried to figure out some conditional formatting, but to no avail. Also, on occasion I have spreadsheets with 5 or 6 sheets containing these mixed addresses. Is there a solution that won't be limited to just a few sheets for comparison?

Excel Help.xlsx

## Copy Non-Matching Data Between 2 Sheets To Another

Apr 18, 2008

I am trying to find a way of comparing entries in one spreadsheet to another spreadsheet and generating a third sheet of those that do not match.

As an example, I have a spreadsheet of approved supplyers, with name, reference and date in each column, and a speadsheet of used supplyers, some with references and some without. I want to compare the supplyers used to the approved supplyers list by reference number (which are in the same format), and produce a third sheet listing all those that do NOT match e.g. unapproved supplyers.

I need to make sure that the third spreadsheet only lists each seperate supplyer once, even though they may have been used several times, AND it must also include supplyers without a reference number.

I will use this to compare many spreadsheets with the same data, but of varying length and would like to use a macro to perform this function.

## Extracting Matching Data From Two Sheets Into Third Sheet?

Jan 17, 2014

I'm not sure if this is best handled in the Formulas & Functions section or elsewhere, but this is my best guess. I have a spreadsheet used for tracking hardware issues with data in two worksheets:

1. PageCount
Column 1: Date
Column 2: Serial#
Column 3: PageCount

2. Tickets
Column 1: Date
Column 2: Serial#
Column 3: TicketNumber

What I'm trying to do is find a way to extract from those two sheets the date, serial number, page count, and ticket number where the date / serial # are the same and dump this to a new sheet. I've thought that I may need to concatenate the date / serial number together into a single cell or something, but I'm really at a loss as to how to pull this data. Part of me thinks this should be done in SQL, not a spreadsheet, but that's how our reports are produced.

## Matching Data On Two Separate Sheets And Copying From One To Another

Jul 16, 2009

If the name in Column F of "Sheet1" is found in "DataPEs" in Column B, then copy the block of 6 cells of data below it in column Q to column D of "Sheet1" in their relative rows. Additionally, if column Q has data then copy it, if not then copy the data only in column M. Finally, the number of matching names will vary in Sheet1 but will stay mostly the same in the DataPEs sheet. I've highlighted one block of data in green as an example.

## Pulling And Matching Data From Multiple Sheets?

Aug 7, 2013

I have a workbook with 4 sheets one is called final and the other 3 are data1, data2, and data3. The data sheets have the actual data I am needing to pull from. Each has two rows of data: data1 has employee number in column A and employee code in column B. Data2 has employee code in column A and employee name in column B. Data3 has employee name in column A and employee email in column B. Now I need to pull the info form all three sheets into the sheet names final. So the final sheet needs to contain 4 columns for employee number, employee code, employee name, and employee email. The kicker is the data sheets don't line up with each other within each sheet it does but the first one in data1 is not the first in data3 and so on.

## Compare 2 Sheets & Copy Non Matching Data

Jan 8, 2008

Does anybody have a code snippet to search and compare 2 sheets.

I want to read the value in a cell on the first sheet, then search the entire second sheet for a match, if it does match then copy the value from certain cells on the second sheet to the row on the first.

## Copy Matching Data Between 2 Sheets To 3rd Worksheet

Apr 18, 2008

I have found the following code on this forum that has really worked well. This code matches the first two columns of two worksheets and inputs them into a third worksheet. But I need to be able to copy up to five more columns, a total of seven columns and have it input into the third worksheet. I am not sure what it means "For Each c In Sht1Rng". look at the code and advise me of what I need to do.

Sub FindMatches()
Dim Sht1Rng As Range
Dim Sht2Rng As Range
Set Sht1Rng = Worksheets("Data1").Range("A1", Worksheets("Data1").Range("A65536").End(xlUp))
Set Sht2Rng = Worksheets("Data2").Range("A1", Worksheets("Data2").Range("A65536").End(xlUp))
For Each c In Sht1Rng
Set d = Sht2Rng. Find(c.Value, LookIn:=xlValues)
If Not d Is Nothing Then
Worksheets("Results").Range("A65536").End(xlUp).Offset(1, 0).Value = c.Value
Worksheets("Results").Range("A65536").End(xlUp).Offset(0, 1).Value = c.Offset(0, 1).Value
Set d = Nothing
End If
Next c

End Sub

## Lookup Range Of Cells And Populate Specific Cells Based On Matching Data?

May 23, 2014

I am trying to build a staff roster. The staff rotate over a 4 week cycle. the name of the staff member, and their shift needs to be looked up from the key then matched with the particular week. the name and shift then need to populate specific cells.

I have attached the worksheet so you can see what i am trying to achieve.

## Matching Cells And Replacing Data

Apr 14, 2009

We have a report with 2 different sheets. On sheet one there are 13,000 rows of data and columns A-H are filled with different data. column A is our item id and column G has a date that states when the item was sold last. Well, the date in column G is wrong for about 7800 rows and needs changed.

The second sheet in the file is the 7800 rows with just the item id in column A and the correct date in column B. We are looking for an easy way to replace the rows in the first sheet with the correct information from the rows in the second sheet without manually replacing it line by line.

I almost forgot to add in, that in both sheets, column A with the item ids are the same item ids on both those sheets. So column A on sheet one has 13000 rows and included in those 13000 are the 7800 item ids on sheet 2.

We tried using the VLookup function that is incorporated into excel but had absolutly no luck, mostly because we have never used this function before. Sheet one already has all the lines of sheet 2, its just that sheet one has the wrong dates for the item ids and sheet 2 has the correct dates. im trying to replace the dates on sheet one from the dates on sheet 2 matching on the item ids from both sheets......

## Copy Corresponding Data Based On Matching Cells?

Jul 15, 2014

I am trying to copy a row based on the value of a cell.

I have two sheets in my workbook and on sheet 1, I have a part number and a description. On sheet 2, I have part numbers again, but this time I the description is broken up into the format I need.

What I am trying to do is have excel search on sheet 2 for the part numbers, then copy the information that corresponds to the part number into the correct column.

I have tried using Vlookup. But if the part number in row 2 on sheet 1 match the one in row 8 on sheet 2, this will copy over the data from row 2 whereas I need row 8.

If this would be more doable using VBA, that is fine by me. I haven't been able to figure out anything in VBA or in excel formulas up to this point.

## Aligning Cells Based On Matching Data In Column Pairs?

Aug 13, 2014

I've got 3 pairs of columns and I need to sort through them and align the cells in columns E&F with those in A&B and C&D. The cells I need to match up are the times (columns A, C and E)

Example - convert this:

A...............................B..........C...............................D.........E...............................F......
30/07/2014 14:21:04.....6.10.....30/07/2014 14:22:37.....6.13.....30/07/2014 14:21:04.....6.13
30/07/2014 14:21:06.....6.11.....30/07/2014 14:22:54.....6.13.....30/07/2014 14:22:37.....6.13
30/07/2014 14:22:37.....6.11.....30/07/2014 14:22:56.....6.13.....30/07/2014 14:22:54.....6.13
30/07/2014 14:22:54.....6.11.....30/07/2014 14:22:56.....6.14.....30/07/2014 14:22:56.....6.13
30/07/2014 14:22:56.....6.11.....30/07/2014 14:22:59.....6.13.....30/07/2014 14:22:59.....6.13

Into this:

30/07/2014 14:21:04.....6.10.................................................30/07/2014 14:21:04.....6.13
30/07/2014 14:21:06.....6.11........................................................................................
30/07/2014 14:22:37.....6.11.....30/07/2014 14:22:37.....6.13.....30/07/2014 14:22:37.....6.13
30/07/2014 14:22:54.....6.11.....30/07/2014 14:22:54.....6.13.....30/07/2014 14:22:54.....6.13
30/07/2014 14:22:56.....6.11.....30/07/2014 14:22:56.....6.13.....30/07/2014 14:22:56.....6.13
............................................30/07/2014 14:22:56.....6.14............................................
............................................30/07/2014 14:22:59.....6.13.....30/07/2014 14:22:59.....6.13

I don't know VBA so hopefully there's a way of doing this with a basic Excel function.

## Match Data In 2 Cells In Different Workbooks And Then Copy Results In Matching Row?

Feb 13, 2014

I have 2 worksheets, A and B. In both worksheets there is common data in column A (account ID). I would like to find a way to return all of the data for the matching row in worksheet B and have it pasted into the matching row in worksheet A.

So in the example below, I am looking for a function that will match on Account ID in both worksheets and then paste the results from Dataset 1, 2 and 3 into the row with the matching Account ID in worksheet A.

Worksheet A
Account ID
Column to paste matching rows from Worksheet B

1

2

Worksheet B
Account ID
Dataset 1
Dataset 2
Dataset 3

1
AAA
BB
CC

4
EE
DD
FF

## Compiling Partially Matching Data Into Matching Rows With Macro

Jan 20, 2013

My task is to combine two large databases into one spreadsheet by extending the number of columns. The data from each database is 90% matching based on an identification number, however occasionally there are additional rows or unmatched identification numbers that need to be kept for analysis.

When this happens, there needs to be a blank row inserted to represent the missing data in the rest of the corresponding row.

I am having trouble finding a quick way to do this because I have approximately 12,000 rows (and columns up to DV when combined).

for example:

p1
data
data
data
data
p2
data
data
data
data

[Code] .....

needs to become:

p1
data
data
data
data

[Code] .....

I am guessing I will need a macro of sorts, So far I have made one column that tell me if the ID's are matching or not (1 or 0) and if they are not matching (0) I manually insert the rest of the row that is missing or make space for the duplicate data (which needs to remain).

## Search To Find Matching Cells And Copy/transpose Adjacent Data To Original Sheet?

Nov 12, 2009

I'm trying to find a way to search a second sheet in a workbook for specific criteria outlined in a first sheet (in my attached example, from A3 downwards within the 'list of search criteria' sheet), and then to copy any secondary data found against a successful search match to the original sheet, transposed against its corresponding matched search term.

As you can see in the example, the search term 'bindi' (A4 in the 'list of search criteria' sheet) appears in the 'data' sheet 3 times - the secondary data for these occurences ('feathery', 'Fibonacci', 'glassy') is copied to the 'bindi' row on the first sheet and is offset with each copy to produce a transposed-esque effect of copy and paste.

If it's any help, there are a maximum of 9 matches for a single search term in the real document.

Thanks in advance for your help... I tried to adapt a previous solution given to me for a similar question but failed miserably. I bow humbly to your expertise!

## Matching Two Tables - Copying Data For Matching Value?

Feb 27, 2014

I have two tables, Table1 one has only customer codes in it, and I have Table2 with plenty of customer codes and those customer name, surname, age, location...

And I want to match and copy each of those customer codes in Table 1 all the information which is on Table2

Table 1:
50025
50026
50086

Table 2: Considering that name, age and location is each in separate cell

50025JohnSecond25Location 1
60085EmilyThird 20Location 2
45454Wilhelm Fourth35Location 3
10000RoseFifth 60Location 4
50086JohnySixth 45Location 5
65501JacobSeventh18Location 6
50026Jackie Eighth22Location 7

And the outcame should be that it finds the value from Table1 in Table2 and copy's information in Table 1 like this:

50025 JohnSecond25Location 1
50026 Jackie Eighth22Location 7
50086 Johny Sixth 45Location 5

## Copy Matching And Non Matching Data Into New Worksheet

Feb 20, 2014

I have two worksheet "ABX" and "ACX" from which I want to find the matching data for specific columns B, D and E only.

Matching data will be in sheet "Match" and vice versa.

Data are present dynamically.

## Matching Two Columns Of Two Different Sheets

Jun 3, 2014

My requirement is to match 2 columns of two different sheets. I know about Vlookup for exact matching but here I neeed to do partial matching.

For Example: Sheet1 Company Name= Opera Technologies

Sheet2 Company Name= Opera

Output should be like this in different column: Opera, 104/Main Street

## Matching 2 Rows In 2 Different Sheets

Apr 28, 2009

I have 2 sheets with lots of data in them. On the first sheet in the A column i have data that looks like this: 01234567 On the second sheet in the D column i have data that looks like this: 1234567 It's basically the same data except without the 0 in front. The first sheet has like 60k rows and the second sheet has around 18k rows. I need to find out what data from the second sheet is in the first one. I'm attaching an example.

## Matching 2 Sheets With A Macro

Oct 29, 2009

If I have a list (in sheet 1) of names listed in column "a" and numbers listed in column "b" and the same thing (on sheet 2) and I want to run a macro that takes the data from (sheets 1 and 2) and lists the matching names in column "a" (in sheet 3) and the number associated with the name (in sheet 1) in column b and the number from (sheet 2) in column c

## Matching Values Between Sheets?

Jan 4, 2012

I'm trying to store a value in ColumnA Row1 Sheet1 in a variable and check to see that value exists in Sheet2. If the value is in Sheet2, I want to copy the information in Row1 Sheet1 and paste it in the row of the matching value in Sheet2. I need to then check the value in ColumnA Row2 Sheet1 and check again for it in Sheet2 and I need to continue to do this until the data ends in Sheet1.

Code:
Dim x As String
Dim y As String
A = 2
B = 2

[Code]...

The above is the code I've been trying to use. It has two flaws:

It won't let me copy into the row of Sheet2 (not a big deal though)The rows get all mismatched and it doesn't actually search ALL the rows in Sheet2 so it misses some of the values that actually DO match (the big issue) I've racked my brain for hours trying to figure it out using the above method and I think I've reached the point where I'm overthinking it way too much. I also found the "Find" method but I couldn't quite teach myself how to use it.

## Matching Items From Two Sheets

Mar 24, 2007

I have two majors (classes) listed on two differents sheets and need to put the matching classes on a third sheet.

## Formula For Matching Values In Two Different Sheets Then Getting A Sum?

Aug 13, 2014

I have a spreadsheet where I have two different sheets; a summary sheet, and a more detailed sheet that lists out items on invoices.

The summary sheet shows invoice number, amount invoiced, and total paid against that invoice.

The detailed sheet goes into more details, and shows whats on the invoice, and any reasons for them not being paid.

I want a formula on the summary sheet that picks up the invoice number from the details sheet, and then brings through the figures. The details sheet may have more than one line for an invoice number, so the formula needs to be able to add up too.

I've tried a vlookup, but it doesnt seem to work, and I dont think it will do what I want.

## Merge Two Sheets Based On Matching Value

Feb 10, 2014

I have two sheets with a Unique ID that I'd like to match and generate a third sheet. The third sheet would consist of First Name, Last Name, ID number where the phone numbers match from between sheets.

Sheet 1: A = Fname, B = Lname, C = Phone
Sheet 2: A = message, B = Phone

I'd like to make a Sheet 3: A = Fname, B= Lname, C = Phone, D = Message

Is my only option to try and get on a PC and use MS Access? Never had to do this in Excel before.

## Finding Matching Values In Different Sheets

Oct 11, 2011

I have in Sheet 1 a list of product codes (that should be only numbers, i.e: 1010) on column A, product description on B and a sales column on C.

On Sheet 2 I have on column A I have in the same cell a letter "C" the product code and the product description(i.e.: C1010 Onions). On column B I got the sales total. ( I dont care about the letter "C" it can be deleted)

I would like to use a VBA code to find the same product codes between sheet 1 & 2 and copy the sales total from sheet 2 to sheet 1 when the product code is the same.

## Multiple Sheets Total Matching

Nov 16, 2011

I have one workbook in that 6 sheets have.

Here I want match the total one sheet to another but each sheet there is no fixed ranges so that I have confused.

How to find out Each sheet total and match each other.

## Copy Matching Fields Of 2 Sheets

Jan 8, 2008

I want to filter data using two sheets. i want only the names in a field that are listed on BOTH sheets. i have a two lists of names and i want only the names that are included in both sheets while still including the rest of their information.

## Sum Matching Rows From Multiple Sheets

Jun 14, 2008

I'm working with 2 sheets. Both have the same headings, A1 is CustomerCode, C1 is JAN, D1 is FEB and so on. The CustomerCode column doesn't match exactly between the 2 sheets, because some of the customers from Sheet1 aren't listed on Sheet2. I need a formula to put on Sheet 3 that will Sum the values in JAN, FEB, etc from the first 2 sheets for matching customers, and also bring over the totals from the customers on Sheet 1 that don't have a match on Sheet 2.

I have attached an example of how the finished product would look in my case. But also, here's this:

Sheet1 Charges

CustomerCode JAN FEB
ABC 30 25
AEF 20 15
BBB 50 30
CED 15 20

Sheet2 Misc Charges

CustomerCode JANFEB
ABC 510
BBB 3 8
CED 2 4

Need Sheet3 To look Like this:

Sheet3 Total Charges

CustomerCode JANFEB
ABC 3535
AEF 2015
BBB 5338
CED 1724

New customers are added often, so I have a SQL Query that I can put in column A of sheet3 that will pull the same CustomerCode list as sheet1, so getting the names to sheet3 shouldn't be an issue.