+ Reply to Thread
Results 1 to 4 of 4

Sorting a data list by another data list

  1. #1
    Registered User
    Join Date
    02-16-2010
    Location
    Italy
    MS-Off Ver
    Excel 2003
    Posts
    4

    Sorting a data list by another data list

    Hello,
    i'm quite a newbie to Excel, so forgive if the solution to my problem is evident, but i could not figure it out at the moment, so i'm asking here in hope to obtain some help.
    Let's say you have a sorted list of numbers, to which is associated another list like this:

    1 a
    2 b
    3 c
    4 d
    5 e
    6 f
    7 g
    8 h

    Now i want to sort this list throgh another list, with the same numbers, but with a different order:

    3
    5
    1
    7
    8
    6
    2
    4

    At the same time i would like to keep the original association between the two lists, so that, in the end, i would find such a situation:

    3 c
    5 e
    1 a
    7 g
    8 h
    6 f
    2 b
    4 d

    I've not yet figured out how to solve this problem. The 'data sort' seems to be the most immediate way, but i haven't found an option to sort by confrontation with another list.
    My version is 2003.
    Thank you in advance for any help.

  2. #2
    Forum Expert martindwilson's Avatar
    Join Date
    06-23-2007
    Location
    London,England
    MS-Off Ver
    office 97 ,2007
    Posts
    19,320

    Re: Sorting a data list by another data list

    you can just use a vlookup see attached
    Attached Files Attached Files
    "Unless otherwise stated all my comments are directed at OP"

    Mojito connoisseur and now happily retired
    where does code go ?
    look here
    how to insert code

    how to enter array formula

    why use -- in sumproduct
    recommended reading
    wiki Mojito

    how to say no convincingly

    most important thing you need
    Martin Wilson: SPV
    and RSMBC

  3. #3
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Sorting a data list by another data list

    Hi,

    With your original data in A1:B8, enter your desired order in C1:C8. In D1 enter
    Please Login or Register  to view this content.
    and copy down
    Column D gives the result.

    HTH
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

  4. #4
    Registered User
    Join Date
    02-16-2010
    Location
    Italy
    MS-Off Ver
    Excel 2003
    Posts
    4

    Re: Sorting a data list by another data list

    Thanks to both, solved.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1