Truncate a date time field

  • Thread starter Thread starter Arturo
  • Start date Start date
A

Arturo

I have a view from Oracle that has a date time field. What I need most out of
this field is the time. I can use the date but really don' have to have it. I
have set the data type several different ways. It will display just the time
but the date is still there and interferes with my queries. My queries have
to identify the time specifically.

Here is the display (5/13/2008 3:06:49 AM). When I change the data type I
can get 3:06:49 AM. But this is only what is displayed. The date is still
there.

Is there a way to split this out so that at least I keep the time?

Thank you.
 
Use the TimeValue function. (There's also a corresponding DateValue function
if all you want is the date)
 
Thanks. I searched for TimeValue Function and found a query that worked. Good
job!
 
Arturo

You may be making more work for yourself than you need to.

Keep the "raw" data that's coming from Oracle. Use a query to get the
TimeValue() portion of the field.

Or if you don't need to "do math" on it, consider using the Format property
to display only the time portion...

--
Regards

Jeff Boyce
www.InformationFutures.net

Microsoft Office/Access MVP


Microsoft IT Academy Program Mentor
http://microsoftitacademy.com/
 

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

convert GMT Date & Time 6
Truncate date 5
Date and Time Reporting 1
Date/Time Formatting 4
Convert Date and Time 9
Dlookup 7
Splitting Date and time field 3
Date format in Query 1

Back
Top