删除重名的记录
面试看到这种题。。。。。 我估计考官的正确答案有可能是错的 所以你用了下面这个方式 虽然可用但只会得0分。
delete c from t_people as c ,t_people d where c.name = d.name and c.id <> d.id ;
mysql 可用
面试看到这种题。。。。。 我估计考官的正确答案有可能是错的 所以你用了下面这个方式 虽然可用但只会得0分。
delete c from t_people as c ,t_people d where c.name = d.name and c.id <> d.id ;
mysql 可用
评论功能维护中,当前仅展示历史评论。
这样子估计是最好的解决方案了...
貌似也只能这样呵呵。
把数据插入到临时表中排重 之后再改表名.
有没有标准sql的写法呢?
哈哈 ,抛哥总是很牛。