create
    definer = root@`%` procedure SyncMesData_every_2_hours()
BEGIN

REPLACE into mes_sync.mes_report_task SELECT * from mes_origin.mes_report_task;
REPLACE into mes_sync.mes_crystal_order SELECT * from mes_origin.mes_crystal_order;
REPLACE into mes_sync.mes_poi_formula SELECT * from mes_origin.mes_poi_formula;
REPLACE into mes_sync.mes_feeding_task SELECT * from mes_origin.mes_feeding_task;
REPLACE into mes_sync.mes_feeding_detail SELECT * from mes_origin.mes_feeding_detail;
REPLACE into mes_sync.mes_transport_task SELECT * from mes_origin.mes_transport_task;
REPLACE into mes_sync.mes_furnace_task SELECT * from mes_origin.mes_furnace_task;
REPLACE into mes_sync.mes_furnace_detail SELECT * from mes_origin.mes_furnace_detail;
REPLACE into mes_sync.mes_stick_task SELECT * from mes_origin.mes_stick_task;
REPLACE into mes_sync.mes_production SELECT * from mes_origin.mes_production;
REPLACE into mes_sync.mes_round_bar SELECT * from mes_origin.mes_round_bar;
REPLACE into mes_sync.mes_round_bar_status SELECT * from mes_origin.mes_round_bar_status;
REPLACE into mes_sync.mes_roll_rub_quality_task SELECT * from mes_origin.mes_roll_rub_quality_task;
REPLACE into mes_sync.mes_square SELECT * from mes_origin.mes_square;
REPLACE into mes_sync.mes_lifting_box_task SELECT * from mes_origin.mes_lifting_box_task;
REPLACE into mes_sync.mes_packing_task SELECT * from mes_origin.mes_packing_task;
REPLACE into mes_sync.erp_job_mtl_confirm SELECT * from mes_origin.erp_job_mtl_confirm;
REPLACE into mes_sync.erp_job_mtl_send SELECT * from mes_origin.erp_job_mtl_send;
REPLACE into mes_sync.mes_draw_line_task SELECT * from mes_origin.mes_draw_line_task;
REPLACE into mes_sync.mes_disposable_qc_task SELECT * from mes_origin.mes_disposable_qc_task;

END;

