danielchen Posted June 2, 2015 Share Posted June 2, 2015 Hallo Everybody, Can anybody help me to change a datetime data content into another new column with a datetime mysql format... I attach more information in the follow images...thanks in advance for the help Link to comment https://forums.phpfreaks.com/topic/296611-change-a-datetime-data-content-in-a-string-into-a-datetime-mysql-format-in-php/ Share on other sites More sharing options...
Barand Posted June 2, 2015 Share Posted June 2, 2015 Being from the UK I assume your current dates are dd/mm/yyyy (impossible to tell from your date samples) so adjust as necessary. UPDATE tablename SET fecha = STR_TO_DATE(`Date/Time`, '%d/%m/%Y %H:%i:%s') Link to comment https://forums.phpfreaks.com/topic/296611-change-a-datetime-data-content-in-a-string-into-a-datetime-mysql-format-in-php/#findComment-1513063 Share on other sites More sharing options...
danielchen Posted June 5, 2015 Author Share Posted June 5, 2015 It worked thank you so much...Barand Link to comment https://forums.phpfreaks.com/topic/296611-change-a-datetime-data-content-in-a-string-into-a-datetime-mysql-format-in-php/#findComment-1513314 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.