On duplicate key update. Mysql replace string update пример. update from another table.