MySQL中删除重复记录

Friday, January 29, 2010

mysql > CREATE TABLE tmp AS SELECT * FROM youtable GROUP BY name;
mysql > DROP TABLE youtable;
mysql > ALTER TABLE tmp RENAME youtable;

可以用Python写个脚本来处理重复, 也是很简单的!

This entry was tagged MySQL

comments powered by Disqus

© 2009-2013 lxneng.com. All rights reserved. Powered by Pyramid

go to Top