select t.title,
avg(s.salary)
from salaries s join titles t
on s.emp_no = t.emp_no 
group by t.title