ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Change data in a single column from "last, first" to "first last" (https://www.excelbanter.com/excel-discussion-misc-queries/79873-change-data-single-column-last-first-first-last.html)

Jeanne

Change data in a single column from "last, first" to "first last"
 
I have a column of names that I want to export to a mail merge. It's a single
column with last name separated by comma followed by first name. How do I
change it to first name and last, no comma


David McRitchie

Change data in a single column from "last, first" to "first last"
 
Hi Jeanne,

http://www.mvps.org/dmcritchie/excel/join.htm#firstname
for both macro solution and worksheet solution.

A worksheet solution is:
=TRIM(MID(A2,FIND(",",A2)+1,99))&" "&LEFT(A2,FIND(",",A2)-1)
This allows for there to be a space or no space after the comma in the original.

---
HTH,
David McRitchie, Microsoft MVP - Excel [site changed Nov. 2001]
My Excel Pages: http://www.mvps.org/dmcritchie/excel/excel.htm
Search Page: http://www.mvps.org/dmcritchie/excel/search.htm

"Jeanne" wrote in message ...
I have a column of names that I want to export to a mail merge. It's a single
column with last name separated by comma followed by first name. How do I
change it to first name and last, no comma




BigPig

Change data in a single column from "last, first" to "first last"
 
H Jeanne,

If you Names are in Column A, and the last and first are separated by a ","
then:
In column B, you could put:
=MID(A1,FIND(",",A1)+2,LEN(A1)-(FIND(",",A1)+1))

Hope this helps.




All times are GMT +1. The time now is 08:54 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com