码迷,mamicode.com
首页 > 其他好文 > 详细

Ch2 Relational model and Relational operation

时间:2016-05-17 00:36:12      阅读:195      评论:0      收藏:0      [点我收藏+]

标签:

I.Relation

1.Definition:strict definition of table

2.Relational schema:R(A1:D1,A2:D2,...,An:Dn) in short: R(A1,A2,...,An)

3.Factors:

  a.column is homogeneity.

  b.it is tolerable that different columns come from same domain.

  c.the names of columns must be different.

  d.the location of columns are exchangeable, so do rows.

  e.every two tuples must have some differences.

  f.attribute is indivisible.

4.Candidate key:an attribute group which could identity a tuple uniquely.

5.Primary key:chose a primary key when there are many candidate keys.It should be a attribute that would change rarely or never change.

6.Primary attribute:the attribute involved in candidate keys, conversely, non primary attribute.

7.Foreign key:an attribute group in relation R,which is not the candidate key of R and correspond to the primary key of relation S.

II.Relational Model

1.three intergrity constraints:entity intergrity、relational reference intergrity、user defined intergrity

2.Compatibility:the two operating relations and their related attributes must have correspondence、comparability、relevance of meaning.(union,difference,intersection operation)

 

III.Relational Algebra Operation

1.Set operation:

union,difference,intersection

2.Cartesian Product

RXS:it is composed of all of the stitch or connection between the tuple of relation R and the tuple of relation S possiblely.

 

(To be continued)

 

Ch2 Relational model and Relational operation

标签:

原文地址:http://www.cnblogs.com/Renxj/p/5499994.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!