Extracting a date

RID

New Member
Joined
Dec 17, 2009
Messages
17
Good Morning

Is it possible to use a formula to extract a date from automated assigned ID. For instance our software for reporting incidents produces an ID number which is in the form of text and numbers AC-INC-20180511-005 for example. The date is the number 8 figure number within this produced number in YYYYMMDD format, is there a formula that can be used to extract this number into another cell without having to manually input?

regards

Neil
 

Excel Facts

What is the last column in Excel?
Excel columns run from A to Z, AA to AZ, AAA to XFD. The last column is XFD.
See if this helps.

=0+TEXT(MID(A1,FIND("-20",A1)+1,8),"00\/00\/00")
 
Upvote 0
If your ID numbers always consist of 2 characters, a dash, 3 more characters, another dash and then the 8-digit date value, then you can use this formula to retrieve the date...

=0+TEXT(MID(A1,8,8),"0000-00-00")

This returns the date serial number so you will need to then format the cell you put this formula in with the date format of your choosing.
 
Upvote 0

Forum statistics

Threads
1,214,585
Messages
6,120,394
Members
448,957
Latest member
Hat4Life

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