1. Why are tuples in relationships not sequential?
2. Why is a duplicate tuple not allowed in a relationship?
3. What is the difference between a relationship and a regular table or file?
4. What is the difference between Cartesian product, equivalent connection and natural join?
1. A: Because a relationship is a collection, it does not take into account the order between tuples, that is, there is no row order.
2. A: If there is a duplicate tuple in the relationship, then the key cannot be used to identify the unique tuple. Therefore, the relationship is limited in the relational model.
3. A: In a nutshell, relationships are a standardized two-dimensional form in which relationships are regulated by the following normative constraints:
(1) Each attribute value in a relationship is not decomposed.
(2) The same tuple (no duplicate tuples) is not allowed in the relationship.
(3) Because a relationship is a collection, the order of tuples is not considered, that is, there is no row order.
(4) In tuples, attributes are theoretically unordered, but they are used to consider the order of the columns.
4. A: The Cartesian product operates on two relationships R and S, and the number of tuples in the relationship is the product of the number of tuples in two relationships. The equivalent join is the selection operation on the result of the Cartesian product, and selects the tuple with the same component value as the first part of the relation (R+J). A natural connection is a projection operation on the basis of an equivalent join (conditional on the equality of public property values), removing the Public property column in S, and when two relationships have no public properties, Natural connections are converted into Cartesian product.