There are two methods to work around this behavior.
Method 1
Create a query with a calculated field to format the date field
appropriately, and then export the results of the query. To do so, follow these steps
-
Perform steps 1 through 4 in the "Steps to Reproduce Behavior" section later in this article.
- Create the following new query based on the TestDate table:
Query: ExportDates
------------------------------------------------
Type: Select Query
Field: Birthday2: Format([Birthday], "mm/dd/yy")
NOTE: The calculated field name cannot match the name of any other field that is included in the query.
-
Save the query and close it.
-
Export the query.
Method 2
Access can create a fixed-width text file, using the "Text (Fixed Width)" export format. Using this method, you can set the size of the date field to 10 characters in the Export specification. This truncates the time portion of the date field during export.
NOTE: This method assumes you have the
Four Digit Years and
Leading Zeroes in Dates options checked in the
Export Specification dialog box.
NOTE: Most common text exports require the data to be delimited using the Text (Delimited) format. Method 2 is not useful in these cases.