一条查询语句不会写,请教各位一下! select col1,col2,col3,count(*) from mytable group by col1, col2, col3having count(*)=1; 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 select DISTINCT col1,col2,col3 from mytable 同意弱水老大,用group by分组,然后通过having字句求出所有不唯一的值。select col1,col2,col3 from table group by col1, col2, col3having count(1)=1; xiaoduoliu (): 你说的'不重复的记录'是针对col1,col2,col3而言? 换一个思路:select * from t1where rowid in (select min(rowid) from t1 group by c1,c2,c3) 许多东西都可以通过看GUIDE HELP解决 不重复可以这样http://www.oradb.net/sql/find0.htm若根据另一条件select * from table_name where (col,col2,col3) in (select col1,col2,col3 from table_name 条件); 遇到 oracle 错误 1455 转换列溢出整数数据类型 导出终止失败 Oracle 8i安装问题 Oracle数据库,怎么让日期字段自动添加日期时间 使用RMAN这么复杂? 求一个sql 语句 系统崩溃,Oracle数据库文件还在,重装Oracle后如何恢复数据库? imp和exp的简单问题 快来帮忙啊,监听器启动不了了!! 请教 谁有办法实现我的这个目的 OracleOraHome81TNSListener不能启动? oracle如何在98下安装?
select col1,col2,col3 from table
group by col1, col2, col3
having count(1)=1;
select * from t1
where rowid in
(select min(rowid) from t1 group by c1,c2,c3)
http://www.oradb.net/sql/find0.htm若根据另一条件
select * from table_name where (col,col2,col3) in (select col1,col2,col3 from table_name 条件);