




版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請進(jìn)行舉報或認(rèn)領(lǐng)
文檔簡介
1、重 慶 交 通 大 學(xué)學(xué) 生 實(shí) 驗(yàn) 報 告實(shí)驗(yàn)課程名稱 數(shù)據(jù)庫原理 開課實(shí)驗(yàn)室 數(shù)學(xué)實(shí)驗(yàn)室 學(xué) 院 理學(xué)院 年級 2012 專業(yè)班 信息與計算科學(xué)2班 學(xué) 生 姓 名 西西里孩子 學(xué) 號 68431685 開 課 時 間 2014 至 2015 學(xué)年第 1 學(xué)期評分細(xì)則評分報告表述的清晰程度和完整性(20分)概念模型的合理性(30分)轉(zhuǎn)換的邏輯模型的合理性(20分)創(chuàng)建對象的SQL代碼正確性(20分)實(shí)驗(yàn)結(jié)果分析(10分)總成績教師簽名數(shù)據(jù)庫原理實(shí)驗(yàn)報告 實(shí)驗(yàn)一 概念模型的建立一、實(shí)驗(yàn)?zāi)康?、根據(jù)給定的題目,把現(xiàn)實(shí)世界中的具體事物抽象為某一概念級的模型,即建立整個問題的概念模型,建立起數(shù)據(jù)庫
2、設(shè)計人員與用戶之間的交流,為數(shù)據(jù)模型的建立奠定基礎(chǔ)。2、學(xué)會認(rèn)識和分析現(xiàn)實(shí)世界,根據(jù)對用戶需求,描述用戶的數(shù)據(jù)要求:(1)練習(xí)如何從中抽取實(shí)體;(2)練習(xí)如何建立各實(shí)體之間的聯(lián)系;(3)從各實(shí)體和實(shí)體間的聯(lián)系,抽取出數(shù)據(jù)處理的過程。二、實(shí)驗(yàn)內(nèi)容及要求(一)實(shí)驗(yàn)內(nèi)容:通過運(yùn)用一些軟件如power designer、編輯工具如WPS等,對多個實(shí)體建立概念模型,通過該方法可以建立直觀的概念模型,再通過該模型來建立邏輯模型和物理模型。(二)實(shí)驗(yàn)要求:1、問題描述某大學(xué)需要使用計算機(jī)管理學(xué)生信息、成績信息等,要求如下:(1)學(xué)生信息管理,包含學(xué)生的基本信息,如學(xué)號、姓名、性別、出生日期等;還要包含學(xué)生的
3、簡歷、社會關(guān)系等;(2)課程管理,包含整個學(xué)校開設(shè)的所有課程;(3)教學(xué)計劃管理,包含設(shè)定各系各專業(yè)在哪學(xué)期開設(shè)什么樣的課程,學(xué)分是多少;(4)學(xué)生選課管理,包含學(xué)生在某學(xué)期選擇什么樣的課程;(5)學(xué)生成績管理,包含學(xué)生各課程的成績、是否補(bǔ)考、補(bǔ)考成績;(6)學(xué)生獎懲管理,管理學(xué)生在校期間所獲得的獎勵和懲罰記錄。2、根據(jù)以上要求,為該大學(xué)的計算機(jī)管理系統(tǒng)建立數(shù)據(jù)庫的概念模型。三、實(shí)驗(yàn)設(shè)備及軟件1、設(shè)備:個人電腦2、軟件:PowerDesigner 15、Microsoft SQL Server 2005、WPS Office 四、設(shè)計方案(一)題目:概念模型的建立(二)設(shè)計的主要思路1、根據(jù)前
4、面所要求的應(yīng)該做的內(nèi)容及其客觀要求,按照步驟進(jìn)行;2、進(jìn)入power designer環(huán)境中,如下圖:3、通過點(diǎn)擊相應(yīng)的圖標(biāo),建立相應(yīng)的對象。如實(shí)體的建立、聯(lián)系的建立等。如下圖:上圖共建立了3個實(shí)體:學(xué)生、課程和學(xué)生選課,在該模型中,也表明了各實(shí)體之間的聯(lián)系,如學(xué)生和課程之間有一對多的聯(lián)系,課程和學(xué)生選課之間也具有一對多的聯(lián)系。3、實(shí)體屬性的建立雙擊實(shí)體對象,彈出實(shí)體描述對話框;如下圖:要求輸入輸入實(shí)體的名稱(name)、實(shí)體代碼(code)、實(shí)體標(biāo)簽(label)。點(diǎn)擊attributes(屬性)按鈕,進(jìn)入實(shí)體的屬性輸入框,如下圖:在彈出框中輸入多個屬性,包含屬性的名稱(name)、代碼(c
5、ode)、數(shù)據(jù)類型(data type),對于數(shù)據(jù)類型可以選擇,如下圖:在輸入屬性時注意屬性的特性:I:為主碼(在PowerDesigner 15里P為主碼);如果是主碼,則表明該屬性唯一標(biāo)識一個實(shí)體。M:為是否允許為空;如果選中,則表示該屬性不允許為空。(三)主要功能1、通過整體把握,能夠?qū)W(xué)生的基本信息(如學(xué)號、姓名、性別出生日期、社會關(guān)系、學(xué)生簡歷)進(jìn)行統(tǒng)一的、有效地管理;2、能清晰的描繪出關(guān)于學(xué)生實(shí)體以及有和學(xué)生有關(guān)系的實(shí)體情況,可以對學(xué)校開設(shè)的課程進(jìn)行管理;3、能對教學(xué)計劃、學(xué)生選課、學(xué)生成績、學(xué)生獎懲進(jìn)行管理;五、主要代碼/*=*/* DBMS name: Microsoft SQ
6、L Server 2005 */* Created on: 2014/12/23 19:01:33 */*=*/if exists (select 1 from sysobjects where id = object_id('cla') and type = 'U') drop table clagoif exists (select 1 from sysobjects where id = object_id('col') and type = 'U') drop table colgoif exists (select 1
7、from sysobjects where id = object_id('jcxm') and type = 'U') drop table jcxmgoif exists (select 1 from sysobjects where id = object_id('ltest') and type = 'U') drop table ltestgoif exists (select 1 from sysobjects where id = object_id('maj') and type = 'U&
8、#39;) drop table majgoif exists (select 1 from sysobjects where id = object_id('nat') and type = 'U') drop table natgoif exists (select 1 from sysobjects where id = object_id('"plan"') and type = 'U') drop table "plan"goif exists (select 1 from sys
9、objects where id = object_id('pol') and type = 'U') drop table polgoif exists (select 1 from sysobjects where id = object_id('selcla') and type = 'U') drop table selclagoif exists (select 1 from sysobjects where id = object_id('shehuiguanxi') and type = 'U
10、') drop table shehuiguanxigoif exists (select 1 from sysobjects where id = object_id('stu') and type = 'U') drop table stugoif exists (select 1 from sysobjects where id = object_id('stufencon') and type = 'U') drop table stufencongoif exists (select 1 from sysobje
11、cts where id = object_id('stuhj') and type = 'U') drop table stuhjgoif exists (select 1 from sysobjects where id = object_id('stutext') and type = 'U') drop table stutextgoif exists (select 1 from sysobjects where id = object_id('term') and type = 'U')
12、 drop table termgoif exists (select 1 from sysobjects where id = object_id('xueyear') and type = 'U') drop table xueyeargoif exists (select 1 from sysobjects where id = object_id('xykcgl') and type = 'U') drop table xykcglgo/*=*/* Table: cla */*=*/create table cla ( c
13、lano varchar(10) not null, clana varchar(40) not null, constraint PK_CLA primary key nonclustered (clano)go/*=*/* Table: col */*=*/create table col ( colno varchar(10) not null, colna varchar(40) not null, constraint PK_COL primary key nonclustered (colno)go/*=*/* Table: jcxm */*=*/create table jcxm
14、 ( jxno varchar(10) not null, jxna varchar(60) not null, constraint PK_JCXM primary key nonclustered (jxno)go/*=*/* Table: ltest */*=*/create table ltest ( ltestno varchar(10) not null, ltestna varchar(20) not null, testtime float not null, constraint PK_LTEST primary key nonclustered (ltestno)go/*=
15、*/* Table: maj */*=*/create table maj ( majno varchar(10) not null, colno varchar(10) not null, majna varchar(40) not null, constraint PK_MAJ primary key nonclustered (majno)go/*=*/* Table: nat */*=*/create table nat ( natno varchar(6) not null, natna varchar(30) not null, constraint PK_NAT primary
16、key nonclustered (natno)go/*=*/* Table: "plan" */*=*/create table "plan" ( majno varchar(10) not null, clano varchar(10) not null, xyeno varchar(6) not null, termno int not null constraint CKC_TERMNO_PLAN check (termno in (1,2), xuefen float not null, constraint PK_PLAN primary k
17、ey nonclustered (majno, clano)go/*=*/* Table: pol */*=*/create table pol ( polno varchar(10) not null, polna varchar(40) not null, constraint PK_POL primary key nonclustered (polno)go/*=*/* Table: selcla */*=*/create table selcla ( majno varchar(10) not null, clano varchar(10) not null, stuno varcha
18、r(15) not null, ltestno varchar(10) not null, constraint PK_SELCLA primary key nonclustered (majno, clano, stuno)go/*=*/* Table: shehuiguanxi */*=*/create table shehuiguanxi ( stuno varchar(15) not null, gxno varchar(6) not null, gxna varchar(40) not null, constraint PK_SHEHUIGUANXI primary key nonc
19、lustered (stuno, gxno)go/*=*/* Table: stu */*=*/create table stu ( stuno varchar(15) not null, stuna varchar(40) not null, majno varchar(10) not null, nianji int not null, sex char(2) not null default '1' constraint CKC_SEX_STU check (sex in ('1','2'), natno varchar(6) not nu
20、ll, polno varchar(10) null, birt datetime null, constraint PK_STU primary key nonclustered (stuno)go/*=*/* Table: stufencon */*=*/create table stufencon ( stextci int not null, majno varchar(10) not null, clano varchar(10) not null, stuno varchar(15) not null, gfen float not null, constraint PK_STUF
21、ENCON primary key nonclustered (stextci, majno, clano, stuno)go/*=*/* Table: stuhj */*=*/create table stuhj ( stuno varchar(15) not null, jxno varchar(10) null, constraint PK_STUHJ primary key nonclustered (stuno)go/*=*/* Table: stutext */*=*/create table stutext ( stuno varchar(15) not null, jlthin
22、g text not null, constraint PK_STUTEXT primary key nonclustered (stuno)go/*=*/* Table: term */*=*/create table term ( termno int not null constraint CKC_TERMNO_TERM check (termno in (1,2), xyeno varchar(6) not null, constraint PK_TERM primary key nonclustered (termno, xyeno)go/*=*/* Table: xueyear */*=*/create table xueyear ( xyeno varchar(6) not null, constraint PK_XUEYEAR primary key nonclustered (xyeno)go/*=*/* Table: xykcgl */*=*/create table xykcgl (
溫馨提示
- 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
- 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
- 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會有圖紙預(yù)覽,若沒有圖紙預(yù)覽就沒有圖紙。
- 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
- 5. 人人文庫網(wǎng)僅提供信息存儲空間,僅對用戶上傳內(nèi)容的表現(xiàn)方式做保護(hù)處理,對用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對任何下載內(nèi)容負(fù)責(zé)。
- 6. 下載文件中如有侵權(quán)或不適當(dāng)內(nèi)容,請與我們聯(lián)系,我們立即糾正。
- 7. 本站不保證下載資源的準(zhǔn)確性、安全性和完整性, 同時也不承擔(dān)用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。
最新文檔
- 特價出售設(shè)備合同協(xié)議
- 班車車輛承運(yùn)合同協(xié)議
- 用人試用期合同協(xié)議
- 電腦分期買賣合同協(xié)議
- 瓜子產(chǎn)地購銷合同協(xié)議
- 電梯管理聘用合同協(xié)議
- 牽制合同補(bǔ)充協(xié)議范本
- 生物醫(yī)療研發(fā)合同協(xié)議
- 班車司機(jī)租賃合同協(xié)議
- 班組代表勞動合同協(xié)議
- 學(xué)校食堂管理員崗位職責(zé)
- 基礎(chǔ)工程課程設(shè)計任務(wù)書及例題
- 江蘇省淮安市2023年中考化學(xué)真題試題
- GB/T 20446-2022木線條
- YS/T 922-2013高純銅化學(xué)分析方法痕量雜質(zhì)元素含量的測定輝光放電質(zhì)譜法
- SMT員工,工藝培訓(xùn)資料
- GB/T 818-2016十字槽盤頭螺釘
- GB/T 6026-2013工業(yè)用丙酮
- JB-T 14226-2022 機(jī)械密封摩擦材料組合的極限pcv值試驗(yàn)方法
- GB/T 21923-2008固體生物質(zhì)燃料檢驗(yàn)通則
- GB 811-2010摩托車乘員頭盔
評論
0/150
提交評論