select distinct为什么删除不了重复值
A黎默然 2020-09-15 03:43:42 我从智联招聘找了382条数据,
为什么我用Navicat写以下,可以得到379条数据:
select * from abc;
start transaction;
create table abc_new select distinct * from abc;
delete from abc;
insert into abc select * from abc_new;
drop table abc_new;
commit;
而这样写还是得到382条数据:
select * from abc;
start transaction;
select distinct * from abc;
commit;
或者这样写也是得到382条数据:
select * from abc;
start transaction;
create table abc_new select distinct * from abc;
commit;
请问我select distinct用法哪里错了?谢谢