We help IT Professionals succeed at work.
Get Started

MS Access how to import string into Date/Time

AndyC1000
AndyC1000 asked
on
447 Views
Last Modified: 2015-05-04
Dear all,

I have an excel file that I'm importing into access.  One of the columns (fields to import) contains date information i.e. 01/05/2012 00:00:00 Tue.  When I import it into Access as a Date with Time I end up with import errors and it doesn't work.  I tried to change the format of the excel cells to Date but it makes no difference.

My next step is to link records by date, this table and another table where the Date is separate fields Month, Day, Timestep. The timestep is an integer from 1 to 48 for each day (half hourly data for one day).

How do I import this data into the database?  I don't need the actual day information (i.e. Tue).  Is it possible to parse the date using VB script or a macro into Year, Month, Day, Hour, Minute, Second etc.? Or include the timestep for the time?

Thanks
Comment
Watch Question
CERTIFIED EXPERT
Most Valuable Expert 2015
Distinguished Expert 2018
Commented:
This problem has been solved!
Unlock 2 Answers and 2 Comments.
See Answers
Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

  • Troubleshooting
  • Research
  • Professional Opinions
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE