Dan Nelson wrote:

>>Is there a way to specify the Date Format for an INSERT statement?
>>
>>Something like:
>>
>> INSERT INTO tblMyTable(myDate) VALUES(DATE_FORMAT('USA', '12-31-2004');
>>    
>>
>
>Try the STR_TO_DATE function:
>
>SELECT STR_TO_DATE('12-31-2004','%m-%d-%Y');
> 2004-12-31
>  
>


Yup.. that works... Thanks.

INSERT INTO `test` (`mydate`) VALUES(STR_TO_DATE('12-31-2004', '%m-%d-%Y'));






-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to