Store 2
Store 2
open c
open c
Exercise:
select
@mark=sum(r.mark*sub.credits)/sum(sub.credits
)
from student s, result r, subject sub
where s.ID=r.studentID and r.mark is not
null
and r.subjectID=sub.ID and
s.ID=@StudentID and r.times > = all
(select r1.times from result r1
where r1.studentID=s.ID and
r1.subjectID=sub.ID
)
end
go