Converting partial text date to numeric value date

snezana

New Member
Joined
Sep 4, 2014
Messages
20
I want to calculate the ages of the people in a data set.
Unfortunately, their birth dates are plain text values, "1 August 2000".
I've tried a bunch of things, but can't work it out. I want to convert the values from "1 August 2000" to its numerical equivalent, like "1/8/2000".
So that I can use that to calculate the age based on this birth date (I tried doing it with the text value I have, using TRUNC(YEARFRAC but ofc since it's basically plain text it doesn't return any value).
The extra challenge I have is that I work with English languaged excel, and the months are in Dutch (so augustus instead of august), which probably adds another layer of complexity :')
Anyone have any good ideas?
 

Excel Facts

Test for Multiple Conditions in IF?
Use AND(test, test, test, test) or OR(test, test, test, ...) as the logical_test argument of IF.
you can change cells format to custom with "d/m/yyyy" type
 
Upvote 0
  1. Convert the column to date or number - This will help you identify which cells still have problem
  2. Select entire column and use find and replace
    1. " augustus " to "/"
    2. Obviously you have to do 12 Find and Replace - 1 for each month
I believe that should work for you
 
Upvote 0
If the cell is indeed a text and not a date:

what version o excel are you using.
for 365 versions:
=date(
1*textafter(A1," ",2),
XMATCH(textafter(textbefore(A2," ",2)," ") ,{"January","February","March","April","May","June","July","August","September","October","November","December"},0),
1*textbefore(A2," "))

for non 365 versions you can use other ways to figure out the components.
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,171
Members
453,021
Latest member
Justyna P

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top