Change birthdate format

I have a birthday field formatted as mm\dd\yyyy and I need to format it as ccyymmdd.  For example the existing date is 11/24/1929 and I need to change it to 19291124.  
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.


Simply change the format of the field in design view to yyyymmdd, this will retain all your current data but display it in the format you want.

To do this select the Table and go into design view, Select the date field and look at the properties below. The top one is format, change it the text above.

PeppermintAuthor Commented:
I actually need to change the date and not just how it appears.  How do I do that?  Thanks

Dates in Access are actually numbers that count the number of elapsed days since 30/12/1899.

For example the 01/01/2003 is actually 37622 as far as Access is concerned.

So you can only change how the date looks in tables and forms, using the Format.

This is OK though, because any calculations or work you do on the date field use the format information to see how it is displayed.

If you asked for the last two digits of 01/02/2003 when it is formated as yyyymmdd you would get 01 because Access knows the field looks like 20030201 to the user.

Is it any clearer now, if not let us know.


Become a Microsoft Certified Solutions Expert

This course teaches how to install and configure Windows Server 2012 R2.  It is the first step on your path to becoming a Microsoft Certified Solutions Expert (MCSE).

Stephen's answer is all you need and can have.

Access does not store dates in any format, just as numbers.  YOU have to apply the format for display.

>> For example the existing date is 11/24/1929 and I need to change it to 19291124

This is changing the format, not changing the date.

changing the format yyyymmdd will result in the display you want.

I think you have to be a little more specific on what you want, as to me the question seems answered, but it is not what you are looking for, so you want something else.
PeppermintAuthor Commented:
The trouble is I need to convert the date for the program.  It's ok if the data type is a number or text but it needs the value needs to be stored as 19291124.  Therefore, I have to take the current value of 11/24/1929 and eliminate the "/" and move the year to the beginning, etc.

I'm not exactly sure the reason behind storing the date in a format except to meet some European standard,  but dunno really. Needless to say, I have to actually change the value.  Hope this helps.

Can you change the value in a query instead of the table?

If you want to change the value, you need a new field to hold the value you want to see and set it to text or number.

SET NewField = Format(OldDate,"yyyymmdd")


Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial

Make a table that has all the same fields as the original but with the Birthday field, change it to a text field. Then do an append query from the first table to the second.

In the birthday field put the following code instead of the field name:

NewBirthday: Right([Date],4) & Left([Date],2) & Mid([Date],4,2)

This will convert the original date to the format you want in a text field.

I hope this helps. If you need more info let me know.

PeppermintAuthor Commented:
Thanks again Joe!!!  Please check the new questions, I have an easy one for ya!
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft Access

From novice to tech pro — start learning today.