Date/Time format not kept in export to Excel

  • Thread starter Thread starter Mark
  • Start date Start date
M

Mark

Am having a problem where formatted field in resultant
query is not kept when exporting to csv or txt file.
Result in query formatted for date but when exported to
file date and time are contained in field. Has anyone had
a similar issue and if so how did you sort it out.

Regards
 
I have a similar, but different problem, in that I am
having trouble linking a CSV to an Access database.

The date is formatted properly in the CSV, but isn't
recognized by Access as a valid date.

On the other hand, the same exact CSV file can be brought
into Excel, saved as an XLS, and then when I link the XLS
file into Access, it sees the date field just fine.

Any idea why this is? I don't see why it should be
necessary to convert the CSV file to XLS first, in order
to get it to work right in Access2000.

Any advice would be helpful.

Thank you,
Michelle
 
Hi Mark,

Use a calculated field in the query, e.g.

fDateField: Format([DateField], "mm/dd/yyyy")
 
John,

Thankyou so much, it worked just like a bought one.
I was having probs. with my syntax and gave up for a while
but am on track again. Thankyou.

Regards,
Mark
-----Original Message-----
Hi Mark,

Use a calculated field in the query, e.g.

fDateField: Format([DateField], "mm/dd/yyyy")

Am having a problem where formatted field in resultant
query is not kept when exporting to csv or txt file.
Result in query formatted for date but when exported to
file date and time are contained in field. Has anyone had
a similar issue and if so how did you sort it out.

Regards

--
John Nurick [Microsoft Access MVP]

Please respond in the newgroup and not by email.
.
 
Back
Top