• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 393
  • Last Modified:

Accesss export with formatting

Dear Experts,

I have a database that uses a few fields that is of data type Date/Time, and want to use is as a time field, such as 6:13.
I am  able to display as such within Access, but when I export to Excel, the whole info comes, date, time with AM/PM.
How can I just export the way I am displaying?
Please advise.
2 Solutions
Scott McDaniel (Microsoft Access MVP - EE MVE )Infotrakker SoftwareCommented:
Build a query that formats the field the way you want, and then export that query. For example:

SELECT Field1, Field2, Format(Field3, "hh:mm:ss") AS MyTimeField FROM MyTable

Save the query, and export it instead of a table.
Rey Obrero (Capricorn1)Commented:
try using a query and format the field, like this

select format([dateField],"h:nn")
from tableName

save the query
then export the query
yballanAuthor Commented:
thank you, that makes sense!
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

The 14th Annual Expert Award Winners

The results are in! Meet the top members of our 2017 Expert Awards. Congratulations to all who qualified!

Tackle projects and never again get stuck behind a technical roadblock.
Join Now