资源描述:
《《数据库整理》数据库上机报告》由会员上传分享,免费在线阅读,更多相关内容在工程资料-天天文库。
1、中国矿业大学矿业学院实验报告课程名称姓名班级学号日期成绩教师1・简单的数据查询(1)答:SELECT*FROMStudentsnoclassnosnamessexsbirthday991204jS9902991203j三9902991202js9902991201je9902991104js9901991103js9901991102js9901991101js9901002102xxOOOl002101xxOOOl001202js9902001201js9902001102js9901001101js9901一桃鹏东平建
2、iia方国苗彬王丽莉一山辉大方男女男男男男女男男女女男女男姚藩葛陈李李王张李李牛王许宋1981-05-071980-02-061979-12-231980-02-081981-05-121981-04-051980-08-081981-10-011980-09-231981-09-191981-06-091980-12-041978-08-011980-04-09(2)答:SELECT丿s_nameFROMStxident
3、snosxtame99120499120399120299120199110499110399110
4、2991101002102002101001202001201001102001101藩陈李李牛王许宋一桃鵬东平建蕾彬王嵯芝方国莉F3H大山方⑶答::>ELECTs_no^s_name?s_birthdayFROMStudent(THERE(s.sex='男丿)Isname►991204991202991201991104991103991101002102峰辉方国一鹏东平建彬王姚葛陈李李张李王一山宋大方1981-05-071979-12-231980-02-081981-05-121981-04-051981-10-01
5、1980-09-231980-12-041980-04-09SELECTs_nam已s_sex^s_birthdayFROMStudentWHERE(s.birthday1980-01-Of)AND(s.sex二,女)snosnamessexsbirthday►001102许裤女1978-08-01(5)答:SELECTsno.sname,ssex.sbirthhy?ROMStudent---YHERE(s.sex二‘男')AND(s.nameLIKE'李蜕)snosnamesbirthday上991104991103
6、002102李平方李建国李王BnDEI-耳--§..・耳-•1981-05-121981-04-051980-09-23(6)答:pELECTs.gs^najTieFROMStudentWHERE(s.nameLIKEsnosname
7、±991204001201王一山(7)答:SELECTt_no,t_name,FROMTeacherWHERE(HOT(t.title二'讲师”))tno11nameIttitle山军霞军菁大为红永桂喔王陈徐徐李田授w懺教熾授授教副助副教教助L000002ZUUUUU4一0000060000
8、07UUUUU8000010(8)答:SELECTs_noFROMChoTcettKERE(scoreISHULL)sno
9、►991102米SQLQueryl.sql-20.^dministrator(54))*□selects_no,scorefromchoicewherescore<60Lorderbyscoredesc41川圉结果J消息s』oscore1•••••••••••••••••••••••I991102158.0i.j(10)答:SQLQueryLsql•20...dministrator(54))*□se
10、lectcourse_nofcourse_namefromCourseLwherecourse」。in(,01001,,,02001,,,02003,)in」结果」消息(11)答:SQLQueryLsql-20._dministrator(54))*□selectt_no,t_name,t_birthdayfromTeacher-wheretbirthday>,1969-12-31,andtbirthday<,1971-1-1,ni口结果冏狮It_not_namet_bifthday1i000004j陈为军197(M)W0
11、0:00:00.000(12)答:SQLQueryLsql・20...dministrator(54))*4rEJselectdistinetcoufromchoice-groupbycoursenorseno,COUNT(sno)astotalIII3課j消息course.nototal
12、01001
13、