【正文】
f @nn3print39。chaoguo39。elseprint39。dx 39。create function aa(@a int,@b int)returns intbeginreturn @a*@b endgoselect (6,4)create function aaa(@a varchar)returns tableasreturn select * from grade where 課程號=@agoselect * from (39。239。)select * from scoreselect studentsID,max(score),min(score),avg(score) from score group by studentsIDselect courseID, count(*) from score group by courseID having count(*)=2select studentsID,avg (score) from score group by studentsID having avg (score)40select studentsID,avg (score) from score group by studentsID having avg (score)40order by avg(score) ascselect * from student order by studept, stAGEselect * from studentsselect * from scoreselect sname score from students score where studentsID=Scode and courseID=39。00139。 and score60select sname score from students inner join score on studentsID=Score where course=39。00139。 and score60select sname, 課程, score from students ,score,course where studentsID=scode and courseID=課程號 and 課程號=39。數(shù)據(jù)庫 39。select sname, 課程, score from students inner join score on studentsID=scode inner join course on courseID=課程號 where 課程號=39。數(shù)據(jù)庫 39。select students.*,score.* from students left join score on studentsID=scodeselect * from tblselect b, identity (int,1,1) as bIDinto tmp from tblselect sum (b) from tmp where bid%20select sum (b) from tmp where bid%2=0