mysql数据库去重语句和不同表之间列的复制语句
1.去重语句:DELETE FROM `v_klg_item` WHERE id NOT IN (SELECT * FROM (SELECT MAX(id) FROM `v_klg_item` GROUP BY NAME) AS tmp);
2.数据库不同表之间列的复制语句:INSERT INTO crm_add (id,address,pid) SELECT id,NAME,parentId FROM labos_area;
1.去重语句:DELETE FROM `v_klg_item` WHERE id NOT IN (SELECT * FROM (SELECT MAX(id) FROM `v_klg_item` GROUP BY NAME) AS tmp);
2.数据库不同表之间列的复制语句:INSERT INTO crm_add (id,address,pid) SELECT id,NAME,parentId FROM labos_area;