如何在oracle中选择计数

如何在oracle中选择计数,oracle,select,count,Oracle,Select,Count,如何计算工作职位的工资 我尝试过这样的编码,但结果是错误的 这是我的密码 select a.job_id,a.job_title,avg(b.salary) gaji_rata_rata from jobs a, employees b where a.job_id=b.job_id order by job_id; 使用聚合函数时需要一个组 select a.job_id,a.job_title,avg(b.salary) gaji_rata_rata from jobs a, emp

如何计算工作职位的工资

我尝试过这样的编码,但结果是错误的 这是我的密码

select a.job_id,a.job_title,avg(b.salary) gaji_rata_rata 
from jobs a, employees b where a.job_id=b.job_id  order by job_id;

使用聚合函数时需要一个组

select a.job_id,a.job_title,avg(b.salary) gaji_rata_rata 
from jobs a, employees b 
where a.job_id=b.job_id  
group by  a.job_id,a.job_title
order by job_id;

使用聚合函数时需要一个组

select a.job_id,a.job_title,avg(b.salary) gaji_rata_rata 
from jobs a, employees b 
where a.job_id=b.job_id  
group by  a.job_id,a.job_title
order by job_id;