嗨我有一张桌子
DATE VALUE NAME
23MAY 156 CONSUMPTION_1
24MAY 122 CONSUMPTION_1
25MAY 122 COMSUMPTION_1
26MAY 122 CONSUMPTION_1
11APR 177 CONSUMPTION_2
12APR 199 CONSUMPTION_2
13APR 199 CONSUMPTION_2
14APR 199 CONSUMPTION_2
19SEP 318 CONSUMPTION_3
20SEP 282 CONSUMPTION_3
21SEP 183 CONSUMPTION_3
现在如何删除所有行的冷冻价值 即
DATE VALUE NAME
23MAY 156 CONSUMPTION_1
11APR 177 CONSUMPTION_2
19SEP 318 CONSUMPTION_3
20SEP 282 CONSUMPTION_3
21SEP 183 CONSUMPTION_3
提前发展
答案 0 :(得分:0)
试试这个:
DELETE FROM MyTable
GROUP BY value
HAVING COUNT(*) > 1;