MySQL Forums
Forum List  »  Newbie

Varchar To DateTime Coonversion
Posted by: AT Barua
Date: September 23, 2016 12:18AM

Hello! I've a table where the date and time is in the following formats:

ID - Date
1 - 10:44:00 10/10/2016
2 - 11:44:00 10/10/2016

I know the conversion using MySQL like SELECT STR_TO_DATE('10/10/2016 14:00','%m/%d/%Y %H:%i'). But is it actually possible to convert above format as follows:

10:44:00 10/10/2016 (Varchar format) - 2016-10-10 10:44:00 (Expected format)

Thanks.

Options: ReplyQuote


Subject
Written By
Posted
Varchar To DateTime Coonversion
September 23, 2016 12:18AM
September 23, 2016 11:16AM
September 23, 2016 11:19AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.