Convert only full birth dates

Turn 2001-11-04 into a real date. Partial or pre-1901 dates are flagged.

What you'll make

In Excel: 2001-11-04 becomes November 4, 2001; 2001-11 becomes Review.

The formula

The formula, with a numbered bracket under each part.
NumberPartWhat it doesResult so far
1AND( … )Checks for 8 digits and a year of 1901 or later.TRUE
2DATE( … )Builds a real date from the year, month and day digits.November 4, 2001
3"Review: keep as partial/early date text"Shown instead for a partial date or an early year.Not used for row 8
4IF( … )Gives the date if the check passes, or else the message.November 4, 2001

Hyphens are ignored, so 2001-11-04 and 20011104 both work. Nothing is made up for a missing month or day.

=IF(AND(LEN(SUBSTITUTE(A8,"-",""))=8,VALUE(LEFT(A8,4))>=1901),DATE(LEFT(A8,4),MID(SUBSTITUTE(A8,"-",""),5,2),RIGHT(A8,2)),"Review: keep as partial/early date text")

How to use it

Yellow bar at the top? Click Enable Editing.

  1. See it work. The Example tab shows 20 made-up examples with the formula already in.
  2. Use your own dates. Paste birth date text like 2001-11-04 into the green column of the Template tab. The dates fill in by themselves.
  3. Move them into your letter. Copy the results. Then use Paste Special and choose Values.

Before you send

Write months and days with two digits, like 1990-07-04. Keep the amber rows as text in your list.

Microsoft's help: DATE function