Import Columns from CSV file in reverse order

Not sure this is even possible but thought I would ask...

I have a CSV file which is update periodically and a connection is refreshed in Excel.  The problem is I want the columns swapped around.

The data comes in as:

Name                                                   Enabled

I want it come in as:

Enabled                                              Name

Is this possible with the Text Import Wizard in Excel or through a different way?

Sonia BowditchInformation Security OfficerAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Rob HensonFinance AnalystCommented:
Is it just the two columns?

If so, import into column B and then Cut and paste column C back to column A
Sonia BowditchInformation Security OfficerAuthor Commented:
It is two columns out of a CSV containing 6 columns and it is used for analysis purposes in a number of spreadsheets.  For this exercise I only want 2 columns which is column 1 and 2.
Rob HensonFinance AnalystCommented:
I am guessing, its not as simple as that.

How about this instead?

Above the imported data insert a new row. Number each column from left to right with 1 to whatever. Number the column for the position that you want them eg, 3, 4, 5, 6, 2, 1  where the last two column are what need to be swapped and placed as the first two columns.

Then highlight the data and use the Sort dialogue to re-arrange the columns.

With the Sort dialogue open, use the Options button at the top to specify Left to Right sort, then specify the new row as a "Sort By" Field. The column will then be arranged in the order required.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Determine the Perfect Price for Your IT Services

Do you wonder if your IT business is truly profitable or if you should raise your prices? Learn how to calculate your overhead burden with our free interactive tool and use it to determine the right price for your IT services. Download your free eBook now!

Sonia BowditchInformation Security OfficerAuthor Commented:
Thanks I do think that will work.
Rob HensonFinance AnalystCommented:
For ease of repetition, you can copy the 6 headers into a list in the order that you need them and then the numbering of the columns in the new row can be done with a formula. the following would be in A1 and copied across to F1.

=MATCH(A$2,$H$1:$H$6,0)   where H1:H6 is the list of headers in the correct order and A2 is the first header of the imported data.

When the new data is imported, import it into A2 and the formulas in row 1 will recalculate. Then do the Sort based on row 1.
Sonia BowditchInformation Security OfficerAuthor Commented:
I will do that.  Thanks very much for your help.
Rob HensonFinance AnalystCommented:
Glad to be of help.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.