Flip surname-first names with no comma

Turn Reed Ava into Ava Reed for greetings and mailing lists.

What you'll make

In Excel: Reed Ava becomes Ava Reed.

The formula

The formula, with a numbered bracket under each part.
NumberPartWhat it doesResult so far
1TEXTAFTER(TRIM(A8)," ")Takes the given names after the first space."Ava"
2" "Adds a space."Ava "
3TEXTBEFORE(TRIM(A8)," ")Adds the surname from before the first space."Ava Reed"
4TRIM( … )Removes any extra spaces."Ava Reed"
5IFERROR( … )With no space, keeps the name as it is."Ava Reed"

Read it left to right. A one-word or empty cell stays as it is.

=IFERROR(TRIM(TEXTAFTER(TRIM(A8)," ")&" "&TEXTBEFORE(TRIM(A8)," ")),TRIM(A8))

How to use it

Yellow bar at the top? Click Enable Editing.

  1. See it work. The Example tab shows 20 made-up names with the formula already in.
  2. Use your own names. Paste surname-first names into the green column of the Template tab. First Last names fill in by themselves.
  3. Move them into your letter. Copy the results. Then use Paste Special and choose Values.

Before you send

This expects a one-word surname first. Fix two-word surnames by hand, like de la Cruz or van Dijk.

Route: Get names ready for the letter

Microsoft's help: TEXTAFTER function