converting a field to a date

T

Terry

I have a field of data type number. the values of the field are

200210
200302
200009
etc.
as in yyyymm

I would like to convert this field to a date field. as in 01/01/2002,
01/02/2003, etc.

Is there anyway to do this?

Thanks
 
R

Rick B

If you only have the month and year, how could Access change it to MMDDYYYY?
Where would it get the DD from?
 
T

Terry

would mm/yyyy be valid?

I was thinking that I would use the first day of the month as the day.
 
R

Rick B

I would add a new field and make it a date field. You don't say what your
field is named. Replace "testtext" in the following with your field name.
I'd then create a query and update my new date field as follows...


DateSerial(Left([testtext],4),Right([testtext],2),1)




Hope that helps.

Rick B
 
G

Guest

Somewhere in here is a detailed response outlining doing just that with an
update query....try a seacrch and see if you have any luck.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top