관계 데이터 모델과 제약조건

  • Published on
    04-Jan-2016

  • View
    51

  • Download
    0

Embed Size (px)

DESCRIPTION

. , , , . I. II. III. IV. . 2. . IBM E.F. Codd 1970 - PowerPoint PPT Presentation

Transcript

<ul><li><p> , , , </p></li><li><p>* </p><p>I. II. </p><p>III. </p><p>IV. </p></li><li><p>*2. IBM E.F. Codd 1970 DBMS 1970 IBM System R1980 DBMS DBMS</p></li><li><p>*2. [2. 1] DBMS </p><p> ORACLE MS SQL Server DB2(SQL/DS) INFORMIXSYBASE MSFT/Access InstanceDB Simple Text</p></li><li><p>*2. () </p></li><li><p>*2.1 () (what) , (how) </p></li><li><p>*2.1 (relation): 2 ( ) (record): (tuple): (attribute): </p></li><li><p>*2.1 ()()EMPLOYEE[2. 1] </p><p>EMPNOEMPNAMETITLEDNOSALARY210622000000342632500000301113000000100312000000</p></li><li><p>*2.1 (domain) CREAT DOMAIN EMPNAME CHAR(10)CREAT DOMAIN EMPNO INTEGERCREAT DOMAIN DNO INTEGER</p></li><li><p>*2.1 EMPLOYEE EMPNAME , , , , . 2.2 EMPNAME .: EMPNAME [2. 2] EMPNAME </p></li><li><p>*2.1 (degree) (cardinality): 1: 0 </p></li><li><p>*2.1 [2. 2] </p><p> /</p></li><li><p>*2.1 (null value) : , DNO() 0 DBMS </p></li><li><p>*2.1 (relation schema) (framework)(1, 2, ... N) (intension) </p></li><li><p>*2.1 (relation instance) (extension) </p></li><li><p>*2.1 [2. 3] EMPLOYEE</p><p>EMPNOEMPNAMETITLEDNOSALARY210622000000342632500000301113000000100312000000</p></li><li><p>*2.1 (relational database) </p><p>DEPARTMENT(DEPTNO, DEPTNEMA, FLOOR)EMPLOYEE(EMPNO, EMPNAME, TITLE, DNO, SALARY)[2. 4] </p></li><li><p>*2.1 [2. 5] EMPLOYEEDEPARTMENT</p><p>EMPNOEMPNAMETITLEDNOSALARY210622000000342632500000301113000000100312000000</p><p>DEPTNODEPTNAMEFLOOR1821039</p></li><li><p>* </p><p>I. II. </p><p>III. </p><p>IV. </p></li><li><p>*2.2 DEPARTMENT[2. 6] </p><p>DEPTNODEPTNAMEFLOOR1821039</p><p>FLOORDEPTNODEPTNAME8110293</p></li><li><p>*2.2 () DEPARTMENT[2. 7] </p><p>DEPTNODEPTNAMEFLOOR1{8, 9}2103{7, 9}</p></li><li><p>*2.2 () </p><p>DEPARTMENTDEPARTMENT=[2. 8] </p><p>DEPTNODEPTNAMEFLOOR1821039</p><p>DEPTNODEPTNAMEFLOOR3921018</p></li><li><p>* </p><p>I. II. </p><p>III. </p><p>IV. </p></li><li><p>*2.3 (superkey), (candidate key), (primary key), (alternate key), (foreign key) : (, ) (, ) () </p></li><li><p>*2.3 : (, ) () (composite key) : (, ) [2. 9] </p><p>11002CS310A011002CS313B+24036CS345B024036CS310A+</p></li><li><p>*2.3 2.10 ? 2.10 ? [2. 10] </p><p>11002sea@hanmail.net24036smkim@iweb.cwunet.ac.kr13427blue@hanmir.com</p></li><li><p>*2.3 : . </p></li><li><p>*2.3 </p></li><li><p>*2.3 : </p></li><li><p>*2.3 [2. 11] </p></li><li><p>*2.3 </p><p>EMPLOYEEDEPARTMENT[2. 13] </p><p>EMPNOEMPNAMEDNO2106234263301111003134273</p><p>DEPTNODEPTNAMEFLOOR1821039</p></li><li><p>*2.3 () </p><p>[2. 13] </p><p>EMPNOEMPNAMEMANAGERDNO2106342623426301133011^1100330111342721063</p></li><li><p>*2.3 () </p><p> ()[2. 14] </p><p>11002CS310A011002CS313B+24036CS345B024036CS310A+</p><p>1100224036</p><p>CS310CS313CS345</p></li><li><p>* </p><p>I. II. </p><p>III. </p><p>IV. </p></li><li><p>*2.4 (data integrity) . . . DBMS </p></li><li><p>*2.4 (domain constraint) , , CHECK SQL2 </p><p> (key constraint) </p></li><li><p>*2.4 (entity integrity constraint) DBMS </p></li><li><p>*2.4 (referential integrity constraint) , R2 R1 R1 </p><p>R1R2</p></li><li><p>*2.4 , , DBMS DBMS , EMPLOYEE DNO DEPARTMENT DEPTNO , DEPARTMENT , EMPLOYEE </p></li><li><p>*2.4 EMPLOYEEDEPARTMENT[2. 17] </p><p>EMPNOEMPNAMEDNO2106234263301111003134273</p><p>DEPTNODEPTNAMEFLOOR182103948</p></li><li><p>*2.4 DEPARTMENT , , , , : EMPLOYEE (4325, , 6) </p></li><li><p>*2.4 , , , 1: DEPARTMENT (4, , 8) 2: DEPARTMENT (3, , 9) </p></li><li><p>*2.4 DBMS (restricted) : DEPARTMENT (3, , 9) (cascade) , : DEPARTMENT (3, , 9) EMPLOYEE 3 </p></li><li><p>*2.4 EMPLOYEEDEPARTMENT[2. 18] </p><p>EMPNOEMPNAMEDNO2106234263301111003134273</p><p>DEPTNODEPTNAMEFLOOR182103948</p></li><li><p>*2.4 DBMS ()(nullify) , : DEPARTMENT (3, , 9) EMPLOYEE 3 </p></li><li><p>*2.4 DBMS DBMS , , , , </p></li></ul>