Home » excel » How can I convert this text date in Excel which will be imported into Access?

How can I convert this text date in Excel which will be imported into Access?

Posted by: admin May 14, 2020 Leave a comment

Questions:

I have a spreadsheet with a text column containing a value like this:

13:09:23 01 JUL 2011

I’m importing this spreadsheet into an Access database, where I need the type to be Date/Time and look like this:

7/1/2011 1:09:23 PM

Would it be easier to change it in Excel before importing it, or deal with it in Access after the import?

I tried adding a new column (B) in Excel and put =DATEVALUE(A1) in B1 which gives me the date correctly. I then tried formatting the column as different Date types, but they all ignore the time and just show 12:00 AM.

How can I get both the date AND time in the format I listed above?

Thanks!

How to&Answers:
=datevalue(A1) + timevalue(A1)

Answer:

set a formula to read =TEXT("YOUR Cell ref","m/d/yyyy h:MM:ss AM/PM") which will force your format.