Datetime to date & time & back

J

John

Hi

I am using and access datetime field to store both date & time. How can I
split it into date & time after reading the field and then combine the date
& time back into datetime when storing it?

Thanks

Regards
 
M

Mary Chipman

Working with datetime always gives one fits when one needs either the
date, the time, but not both. Access stores datetime values internally
as a double, with the date to the left and the time to the right of
the decimal, which you can see if you use a conversion function on
datetime. Often developers find it helpful not to store time values in
datetime, but as integers. The approach you take depends on what you
need to do with the values.

--Mary
 

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

Top