请问怎样查处工资高于所在部门平均工资的员工?谢谢!
解决方案 »
- 数据库优化的问题
- oracle 9i与oracle 10g
- 数据恢复问题
- 100分!请推荐一下Oracle 10g设计数据库的好书
- Oracle 支持Bool or boolean数据类型吗?
- 报错:快照太旧,回退段rbs5 太小。why?
- 删除表示系统提示内存不足怎么解决
- 怎么把图片上传到数据库?
- 诸位高手,到底是ORACLE的产品有实力还是用SQL SERVER更有潜力?
- 红帽子linux7.2下安装oracle的问题
- Oracle9i(64bit)在Solaris10(SPARC)平台上的内存限制!
- Oracle9i在Solaris10平台上以silent方式安装时出现的DISPLAY的问题!
from table_salary
having salary > (select max(salary) from table_salary where department='某部门');
name dept salary
1 1 1000
2 1 1500
3 1 2000
4 1 3000select * from tt where salary>(select avg(salary) from tt)
改为:select a.* from tt a,(select dept,avg(salary) salary from tt group by dept) b where a.salary>b.salary and a.dept=b.dept