Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I am trying to align several different columns in Excel.

My first column looks like this

In addition to that column, I would also have the following:

(the two new columns on the right).

How could I go about aligning those two columns based on the letters (matching them up) while at the same time keeping the same column positions (so the numbers do not move out of the "d" column), the end result being similar to: (forgot to mention, that there may be more items/letters in column a, than what there is in column c)

share|improve this question
add comment

1 Answer 1

up vote 2 down vote accepted

Since column B is empty, you can sort column C and D independently of A. Select or click in the list of data you want to sort, (i.e. anywhere in column C or D). Click the Sort button. Chose how you want it sorted, then click OK. Since there is a separation, column A will not be affected.

If at that point you no longer need column C, then delete it.

If you have more rows in column A then column C (or vice versa), and you don't want to manually match up the rows, then you can use a macro to do so. This example shows how to accomplish such a task using a macro.

share|improve this answer
    
hello, thanks for your help! one question though, if for instance column a had more records than column c, how would i go about matching that up? –  lacrosse1991 Jan 21 '13 at 21:45
    
Well, if columns A and C are sorted, then scroll down the sheet until you find where the two are not matching up, highlight the cells in column C and D that don't match and insert cells above it. Then scroll down the sheet and do the same until they all match up. –  Linger Jan 22 '13 at 2:56
    
the actual amount of rows though is around 3,500 which would make it fairly difficult to do –  lacrosse1991 Jan 23 '13 at 0:01
    
I modified my answer to point you in the right direction of a macro that could do the work for you. –  Linger Jan 23 '13 at 18:46
    
worked perfectly, thanks! –  lacrosse1991 Jan 24 '13 at 16:35
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.