数据库2014试卷及答案

  1. 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
  2. 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
  3. 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。

华南农业大学期末考试试卷(A卷)2014-2015学年第一学期考试科目:数据库系统

考试类型:闭卷考试时间:120 分钟

学号姓名年级专业

Question 1: true-false question (15 points) For each of the following statements, indicate whether it is TRUE or FALSE (Using √for TRUE and ×for FALSE).

1. A primary key is a field (or group of fields) that uniquely describes each record in

the database.

2.Data redundancy improves the integrity of a database.

3.SQL is the language used by relational databases to create objects and to

manipulate and retrieve data.

4. A relational database management system does not include tools for backing up &

restoring databases.

5.An attribute is also known as a row in most databases.

6.An association between entities is known as a relationship.

7.Integrity constraints limit the number of entities that can be placed in a table or

database.

8.The Entity-Relationship data model is often used in the physical design phase.

9.The concept “relation” in relation model is exactly the same as the concept

“relationship” in ER model.

10.Most relationship sets in a database system involves two entity sets.

11.The closure of an attribute set contains that attribute set.

12.Lossless decomposition is necessary in a decomposition algorithm.

13.If A →B and C →D hold, then AC →BD also holds.

14.It is not necessary that a legal schedule preserves the order in which the

instructions appear in each individual transaction.

15.Update operations in database must be written into log before updating database.

Question 2 single-choice question (2 points for each problem, 30 points in total)

1. is the only one incorrect description from the followings:

A. R=(R-S)∪(R∩S)

B. R-S=R-(R∩S)

C. R∩S=S-(R-S)

D. R∩S=S-(S-R)

2. Choose the only one correct expression from the followings: _ ______.

A. (≠ some) ≡ in

B. (= all) ≡ not in

C. exists r ⇔ r ≠ Ø

D. X-Y ≠Ø ⇔ X ⊆ Y

3. of the following four expressions of relational algebra is not equivalent to the other three? They are all based on the relations R(A,B) and S(B,C).

A.()S R B A ,∏

B. ()S R B ∏

C.

()

S R B R A ⨯∏., D.()()()S R R B A ∏⨯∏⋂

4. In the following, assume a is an attribute of some character-string type, e.g. CHAR(10), and that it may be NULL.

Q1: SELECT * FROM R WHERE a IS NULL;

Q2: SELECT * FROM R WHERE a NOT LIKE '%'; A.Q1 and Q2 produce the same answer.

B. The answer to Q1 is always contained in the answer to Q2.

C. The answer to Q2 is always contained in the answer to Q1.

D. Q1 and Q2 produce different answers.

5. The Entity-Relationship data model is

A. DBMS dependent

B. DBMS independent

C. both A and B

D. neither A nor B 6. In SQL, an UPDATE statement without a WHERE clause: A. Updates every row in a table. B. Updates no rows in a table. C. Updates every column in a table. D. Results in a Cartesian product.

7. If a course can be taught by many teachers, and a teacher can teach only one course, then the mapping cardinality from course to teacher is

A. one-to-one

B. one-to-many

C. many-to-one

D. many-to-many

8. If there is a many-to-one relationship between entity A and B, then A. there exists a functional dependency from the primary key in B to the primary key in A, i.e., PK(B) → PK(A).

B. there exists a functional dependency from the primary key in A to the primary key in B, i.e., PK(A) → PK(B).

C. both A and B.

D. neither A nor B

9. If a functional dependency AB →R holds on relation R(A, B, C), then (A, B) is definitely a ______ of R.

A. super key

B. primary key

C. candidate key

D. foreign key

10. A relational schema R is in _____ if the domains of all attributes of R are atomic

A. 1NF

B. 3NF

C. BCNF

D. 4NF 11. Which one of the following statement is true?

A. 3NF is more strict than BCNF

B. 4NF is more strict than BCNF

C. 1NF is more strict than BCNF

D. BCNF is the most strict normal form 12. If a transaction T i has obtain an exclusive lock on data item Q, then transition T j can ______.

A. obtain an exclusive lock on data item Q

B. obtain a shared lock on data item Q

C. wait for lock granting on data item Q

D. read or write Q without a lock

13. If both and appear in the log after the nearest checkpoint to system crash, then transaction Ti must be ______ A. undone B. redone C. deleted D. Neither A or B 14. ______ is the final state in a life cycle of a transaction. A. committed B. aborted C. failed D. A or B

相关文档
最新文档