Convert number yyyymmdd to Date/time mm/dd/yyyy MS Access 2003
Microsoft Access 2003
I have a table with a number field [Brth_DT] with dates setup as yyyymmdd. This field is setup with the data type Number.
I am making a make- table Query to convert this number field to a date field in the new table. I need the new field to be a date field with mm/dd/yyyy.
What expression do I need to use to get this to work in the Query Design View?
If u want it displayed as mm/dd/yyyy you could try changing the format property on the table design.
subsequently doing format("mydatefield","Short Date") will take the format that is defined in your control panel settings
but you can override by doing format("mydatefield","MM/DD/YYYY")
note, only to be done on a date field, not your yyyymmdd field
CInt(Left([Brth_DT], 2)), CInt(Mid([Brth_DT], 3, 2))), DateSerial(CInt(Right([Brt
Greg