Or you could import the date as text and convert dates using:
mysql> SELECT STR_TO_DATE('04/31/2004', '%m/%d/%Y');
-> '2004-04-31'
On Wed, November 14, 2012 06:13, Larry Martell wrote:
> On Tue, Nov 13, 2012 at 9:56 PM, sagar bs <[email protected]> wrote:
>> Hi,
>>
>> As i have the data with some 25 variables in csv file and i need to
>> import
>> to mysql.
>> The issue is that the date format in csv file is dd/mm/yyyy and mysql
>> takes
>> the date format like yyyy/mm/dd.
>> The number of variables in the csv file are same in the table in
>> database
>> of mysql.
>> Please help me out.
>
> Convert the data in your CSV file into the format you need. So many
> ways to do that, e.g.: bring in into excel and change the column's
> format, use sed, use python, use vi, ....
--
Mogens Melander
+66 8701 33224
--
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/mysql