【文章內(nèi)容簡介】
from Student,SC where Cno =39。239。 and Sdept=39。CS39。select * from SC /* 將李勇的數(shù)據(jù)庫成績改為。*/update SC set Grade=85where Sno=(select Sno from Student where Sname=39。李勇39。and Cno=(select Cno from Course where Cname=39。數(shù)據(jù)庫39。select * from SC /* 將選修了號課程且成績?yōu)榭盏倪x課記錄刪除。*/delete from SC where Cno=39。239。 and Grade is null select * from SC /* 從課程表中刪除在選課表中沒有選課記錄的課程記錄。*/delete from Course where Cno not in(select o from SC select * from Course /* 刪除計算機系學生選修了數(shù)據(jù)庫課程的選課記錄。*/delete from SC where Sno in(select Sno from Student where Sdept=39。CS39。and Cno =(select Cno from Course where Cname=39。數(shù)據(jù)庫39。select * from SC /* 求各系的系名及男女生人數(shù)并將結(jié)果保存到另一個表中。*/create table Dept_ssex_count(Sdept char(15,Ssex char(2,Count1 smallintinsert into Dept_ssex_count(Sdept,Ssex , Co