Importing data and sorting by unique identifier

louche_boy

New Member
Joined
Mar 12, 2009
Messages
2
Hi all,

I'm pretty new with excel so thought I would consult this forum.

I have two datalists each with unique identifiers.

Essentially I want to merge the data onto one worksheet but there are more datasets on one sheet than the other.

Example: Worksheet one contains 500 employees with home details etc. and a unique identifier.

Worksheet two contains 300 employees with training details and unique identifier.

Employees are from same workplace. Essentially I would like to move the 300 employees data over to the 1st worksheet and have it automaticcally sorted (or data loaded) by unique identifier, leaving the employees with no training detail blank.

Any help would be appreciated.

Thanks.
Louchie
 

Excel Facts

VLOOKUP to Left?
Use =VLOOKUP(A2,CHOOSE({1,2},$Z$1:$Z$99,$Y$1:$Y$99),2,False) to lookup Y values to left of Z values.
I will take it for granted that the sheet with the 500 Unique Identifiers is Sheet1 and that these are in column A and the home details are in column B.

I will also take it that your 300 Unique Identifiers are on Sheet2 and are in column A and that the training details are in column B.

I will also take it that both Sheet1 and Sheet2 have column headers in row A.

So in cell C2 of Sheet1, insert the following function :

=VLOOKUP(A2,Sheet2!$A$1:$B$301,2,FALSE)

and fill this down column C of Sheet1.

From the Edit menu : Copy and Paste Special values column C over itself.

Then from the Data menu : Sort Sheet1 by column A Ascending

That should sort you out.

Cheers,

D
 
Upvote 0
Sorry - that should have said :

"I will also take it that both Sheet1 and Sheet2 have column headers in row 1"
 
Upvote 0

Forum statistics

Threads
1,214,905
Messages
6,122,172
Members
449,071
Latest member
cdnMech

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
Back
Top