当我尝试运行此查询时:
select branch_no, max (avg_salary)
from (select allocatedto, avg (salary)
from staff, worker
where staff.staff_no = worker.staff_no
group by allocatedto)
as branch_avg (branch_no, avg_salary);
我收到此错误:
Error: near "(": syntax error