I\'ve created a view that contains:
student_full_name subject_code result
Jennifer Higgins CS1234 81
Jennifer Higgins CS1235
Getting the average result should just be a matter of filtering, so you shouldn't need to reference the outer query when calculating the global average. Your pseudo code is very close to what you need. You probably want to convert the where clause to a having clause. You also seem to be after comparing students that are above average students - not students who are performing above the net average. Make sure you're perfectly clear on what the definition of average is.
Something on this form:
select student_full_name, avg(results) as avg_result
from viewEnrol
group by student_full_name
having avg(results) > (
select avg(avg_results)
from (
select name, avg(results) as avg_results
group by student_full_name
)
)