I was using OpenOffice... And I couldn't get it to keep the format yyyy-mm-dd I saw on screen in that format when I went to save it as a text file.... I was able to I suppose this should be reported to their developers as an enhancement.
There's no way to get MySQL to accept dates in a different format when performing the operation on the command line though? Ferindo On 10/16/06, Jerry Schwartz <[EMAIL PROTECTED]> wrote:
I just tested it with Excel, as it will save the date as seen if you save the worksheet to a text file. I do this quite a bit, actually, to put spreadsheet data into MySQL. Often I use Excel macros to construct entire UPDATE or INSERT statements, and save those into a text file for MySQL to inhale. I can't speak for OpenOffice. Regards, Jerry Schwartz Global Information Incorporated 195 Farmington Ave. Farmington, CT 06032 860.674.8796 / FAX: 860.674.8341 > -----Original Message----- > From: Ferindo Middleton [mailto:[EMAIL PROTECTED] ] > Sent: Saturday, October 14, 2006 9:40 PM > To: mysql > Subject: change format of date fields during LOAD DATA INFILE? > > Is there a way to change the format of date fields MySQL is > expecting when > LOADing data from a file? I have no problem with the format > MySQL saves the > date but most spreadsheet programs I use don't make it easy > to export text > files with date fields in the format YYYY-MM-DD even if I > formated the field > that way on-screen. > > It would be great if you could tell MySQL on the command line > to expect > dates in the format Month/Day/Year or something like that and > be able to > interpret that and convert the date to the format it's > expecting on the fly. > > -- > Ferindo >