Skip to content

Latest commit

 

History

History
3 lines (2 loc) · 204 Bytes

update-datetime-field-with-conversion-from-another-in-mysql.md

File metadata and controls

3 lines (2 loc) · 204 Bytes

How to update a datetime field by converting timestamp from another field in same table

UPDATE table_name SET field_to_update=(DATE_FORMAT(FROM_UNIXTIME(timestamp_field), '%Y-%m-%d %H:%i:%s'));