ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   How to separating first and last name (in a single cell... (https://www.excelbanter.com/excel-discussion-misc-queries/3677-how-separating-first-last-name-single-cell.html)

Tommy Boy

How to separating first and last name (in a single cell...
 
I have a worksheet with a persons name in a single cell. I need to sort
these and I forget how to separate them to another set of cells to get the
last name. Since some names have 2, 3, 4 or more separate item (ex: Thomas
G. Roberts, CPA) I can figure it out.

Any help appreciated?

Gordon

Tommy Boy wrote:
I have a worksheet with a persons name in a single cell. I need to
sort these and I forget how to separate them to another set of cells
to get the last name. Since some names have 2, 3, 4 or more separate
item (ex: Thomas G. Roberts, CPA) I can figure it out.

Any help appreciated?


Text to Columns



Tommy Boy

Gordon

Thank you but I tried that and you get 1,2,3,4 or 5 columns this way and
they are not in order. Last name could be in column 2, 3,4 etc. Doesn't
help me in my sort.

Any other ideas?/

Thanks

"Gordon" wrote:

Tommy Boy wrote:
I have a worksheet with a persons name in a single cell. I need to
sort these and I forget how to separate them to another set of cells
to get the last name. Since some names have 2, 3, 4 or more separate
item (ex: Thomas G. Roberts, CPA) I can figure it out.

Any help appreciated?


Text to Columns




Dave Peterson

When I do this, I use Data|Text to columns.

But then I go back and put in a formula in a helper cell.

=counta(A1:E1)

Then I sort by that column (names that look like 2 parts are grouped together
after the sort).

Then it's a manual effort (just dragging the cells to their correct columns).

But since I grouped them nicely, (if I'm lucky) I can grab a few rows of data at
one time and move them to the right/left.



Tommy Boy wrote:

Gordon

Thank you but I tried that and you get 1,2,3,4 or 5 columns this way and
they are not in order. Last name could be in column 2, 3,4 etc. Doesn't
help me in my sort.

Any other ideas?/

Thanks

"Gordon" wrote:

Tommy Boy wrote:
I have a worksheet with a persons name in a single cell. I need to
sort these and I forget how to separate them to another set of cells
to get the last name. Since some names have 2, 3, 4 or more separate
item (ex: Thomas G. Roberts, CPA) I can figure it out.

Any help appreciated?


Text to Columns




--

Dave Peterson

Tommy Boy

Dave

Thank you very much. It worked as you suggested.

TOMMY BOY

"Dave Peterson" wrote:

When I do this, I use Data|Text to columns.

But then I go back and put in a formula in a helper cell.

=counta(A1:E1)

Then I sort by that column (names that look like 2 parts are grouped together
after the sort).

Then it's a manual effort (just dragging the cells to their correct columns).

But since I grouped them nicely, (if I'm lucky) I can grab a few rows of data at
one time and move them to the right/left.



Tommy Boy wrote:

Gordon

Thank you but I tried that and you get 1,2,3,4 or 5 columns this way and
they are not in order. Last name could be in column 2, 3,4 etc. Doesn't
help me in my sort.

Any other ideas?/

Thanks

"Gordon" wrote:

Tommy Boy wrote:
I have a worksheet with a persons name in a single cell. I need to
sort these and I forget how to separate them to another set of cells
to get the last name. Since some names have 2, 3, 4 or more separate
item (ex: Thomas G. Roberts, CPA) I can figure it out.

Any help appreciated?

Text to Columns




--

Dave Peterson



All times are GMT +1. The time now is 12:37 PM.

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