資源描述:
《實(shí)驗(yàn)1實(shí)驗(yàn)環(huán)境搭建》由會(huì)員上傳分享,免費(fèi)在線閱讀,更多相關(guān)內(nèi)容在學(xué)術(shù)論文-天天文庫(kù)。
1、姓名:張悅[實(shí)驗(yàn)名稱]:[實(shí)驗(yàn)日期]:[實(shí)驗(yàn)?zāi)康模?班級(jí):13101班學(xué)號(hào):13110410110實(shí)驗(yàn)環(huán)境搭建2014/10/31掌握在SQLServer數(shù)據(jù)庫(kù)環(huán)境中創(chuàng)建數(shù)據(jù)庫(kù),在數(shù)據(jù)庫(kù)中創(chuàng)建表,以及向表中導(dǎo)入數(shù)據(jù)的方法。[實(shí)驗(yàn)要求]:(1)創(chuàng)建數(shù)據(jù)庫(kù),用自己姓名全拼命名。(2)在數(shù)據(jù)庫(kù)中創(chuàng)建教材58-59頁(yè)表2.34、2.35、2.36的三張表。(3)將Excel文件“課后習(xí)題數(shù)據(jù).xsl”中的數(shù)據(jù)導(dǎo)入到這數(shù)據(jù)庫(kù)表中。[實(shí)驗(yàn)步驟描述]:1.創(chuàng)建數(shù)據(jù)庫(kù)的語(yǔ)句以及截圖。對(duì)象資源官理器語(yǔ)句:createdatabasezhangyue
2、SQLQueryl.sqH3RtftV3R_1?(54))*createdatabasezhangyue日§^£SQLEXPRESS(SQLServer10.50.160(□□雛庫(kù)田系統(tǒng)數(shù)據(jù)庫(kù)田Book田
3、Jlibrary田Sales日ilBBBHBH田CJ^庫(kù)關(guān)系圖田C□表田視圖田罔義詞1.創(chuàng)建Student、Course、SC三張表的SQL語(yǔ)句。創(chuàng)建Student的SQL語(yǔ)句:createtableStudent(snochar(7)primarykey,snamechar(10)notnull,ssexchar(2)ch
4、eck(ssex=,男1orssex=l女1),sageintcheck(sage>15andsage<46),sdeptchar(20)default'計(jì)算機(jī)系'創(chuàng)建Course的SQL語(yǔ)句:createtableCourse(enochar(10)primarykey,cnamechar(20)notnull,ccreditintcheck(ccredit>0),semesterintcheck(semester>0),periodint創(chuàng)建SC的SQL語(yǔ)句:createtableSc(snochar(7),enochar(1
5、0),gradeintcheck(grade>=0andgrade<=100)primarykey(sno,eno),foreignkey(sno)referencesStudent(sno),foreignkey(eno)referencesCourse(eno)2.將Excel中的數(shù)據(jù)導(dǎo)入到這三張表中。請(qǐng)將數(shù)據(jù)導(dǎo)入結(jié)果的截圖粘貼如對(duì)象資源管理器▼早X下。張悅SQLEXPRESS(SQLServer10.50.1aB□踐癢(BQ系統(tǒng)數(shù)運(yùn)洚?[JBook田口Jlibrary?USales曰UzhangyueEJ數(shù)握洚關(guān)系圖張悅
6、SQLEXPRESS】h.-ue?dbo.StudentS振悅SQLEXPRESS?2hangyue?dbo.SCS張悅SQISnoSnameSsexSageSdept9512101李費(fèi)輿19計(jì)算機(jī)系9512102劉晨男20計(jì)算機(jī)系9512103王敏女20計(jì)算機(jī)系9521101張力異22值息系9521102吳薦女21信息系9521103張海輿20傖憲系9531101錢(qián)d評(píng)女18數(shù)學(xué)系9531102王大力異19教學(xué)系NULLNULLNULLNULLNULLE□dbo.Course(S□dbo.CourseSB]dbo.Sc(T□
7、dbo.SCSdbo.StudentS?3dbo.StudentE□田L(fēng)J視圖囡CJ同義詞SC3可菊程性」ServiceBroker對(duì)象g芳官涅器濃悅SQLEXPRESS>2h-ue?dbo.CourseS日Id§^ftSQLEXPRESS(SQLServer10.50.1a日CJ魏庫(kù)sa系縱麟S[JBook田library?[JSalesB[JzhangyueB□'^彥關(guān)系圖曰LJ表田C3翻該田□dbo.Course囡田□]dbo.Sc田□dbo.SCS(B□dbo.Student(±)Odbo.Student!CDifHE
8、SCnoCnamecOl計(jì)算機(jī)文化字c02VBc03計(jì)算機(jī)網(wǎng)絡(luò)c04數(shù)據(jù)庫(kù)基礎(chǔ)COSS等鈐字C06數(shù)搨結(jié)構(gòu)NULLNULL?來(lái)CareditSemesterPeriod對(duì)象資源育涅器曰3^SQLEXPRESS(SQLServer10.50.1△曰Ca娜庫(kù)?cj奈統(tǒng)數(shù)握潭l±lJBookBQlibraryEljSales日J(rèn)zhangyuea□數(shù)握犀關(guān)系圖曰:□表田I」系統(tǒng)表l±lJdbo.Course@□dbo.Course!S□dbo.Sc田0□dbo.Studenta□dbo.StudentSIa□視圖(+ir^3isiia
9、[教師評(píng)語(yǔ)]:324685NULL137624NULL424444NULLSnoCnoGrade9512101cOl909512101c02869512101c06NULL9512102c02739512102c04669521102cOl8295