Merging Data From 2 Worksheets

  • Hi All,

    I have searched for answers and tried a few things put forward but have come up empty. Im hoping I can get some help here.

    I have 2 worksheets. Worksheet A is my working copy and contains around 6000 rows of "active" accounts. Worksheet B is an export from a separate system and contains around 8000 rows. Column A on both worksheets contains an account number, however worksheet B contains about 2000 old account numbers, which I want to ignore. Column B on worksheet B contains a name (text) associated to the account number.

    What I want to achieve is where the account number in column A worksheet A matches that to an account number in column A worksheet B, then copy the name from column B worksheet B to column B worksheet A.

    Does that make sense?

    Thanks in advance.

  • Re: Merging Data From 2 Worksheets

    Hi Glenn

    Could you post the solution please.

    I have some code to do what you were asking but dont have a large database to test it on.

    Would like to see what you came up with?

  • Re: Merging Data From 2 Worksheets

    Well in the end I didnt bother in all honesty.

    I have copied the two sheets together, but now I have duplicate rows on the same sheet. Judging by the threads I read, this seems like an easier fix than the previous one.

    Here is a copy of the current worksheet. As you can see the Account ID is replicated. What I require is a merging of rows where there is a replication of the Account ID (column A) into 1 row. There is not always a replication however and this is still giving me grief.


  • Re: Merging Data From 2 Worksheets

    Im still not sure what you want as far as which columns are to go where.
    I broke your sample sheet into 2 sheets and added some old code of mine (slightly modified).

    This is an example of what can be done but I have a feeling its not what your after if you posted an example of the 2 original worksheets I may be able to help you more.

  • Re: Merging Data From 2 Worksheets

    This will return the Text from column B in SheetB if the same record in column A exists in SheetA column A. If it doesn't exist in SheetB, it returns 0.



    Hope I understood what you were after.


    If absence makes the heart grow fonder, and familiarity breeds contempt, perhaps my wife should live in Darwin?

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!