Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Export then Import txt file problem

Status
Not open for further replies.

Taff82

Programmer
Feb 11, 2004
43
GB
Hi all,

I have a table with several date fields. Next I have a query where I format the date fields so they can be exported in the correct format. I do this as follows:-

Date1: Format ([DATEBRTH],"ddmmyyyy")
Date2: Format ([DATESTRT],"ddmmyyyy")



When I export the file it is saved as a Fixed Width text file. The problem I am having is trying to import the text file and re-formatting the date back to the original format of "dd/mm/yyyy".

Is there anyway to do this?

Thanks for any help.

Taff.
 
Hi cdagenais,

Thanks for the reply,

Have tried what you said to, but when I ran the query out of 105 dates, 95 could not be completed and the other 10 were converted to dates 8 thousand years from now :).

Any other ideas?

Ant.
 
And what about something like this ?
Left(theDate,2) & "/" & Mid(theDate,3,2) & "/" & Right(theDate,4)

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ222-2244
 
Hi PHV,

Thanks for the reply.

That seems to be the only way I will be able to do this.

Thanks.

Taff
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top