【2019】OCP考試062題庫近期考試原題解析-第51題
最新學訊:近期OCP認證正在報名中,因考試人員較多請盡快報名獲取最近考試時間,報名費用請聯系在線老師,甲骨文官方認證,報名從速!
我要咨詢2018年的時候,OCP 11g考試題庫大更新,052 053出現了很多新題,
2019年,11g即將?嫉那捌冢琌racle又出現了一次大變動,12c出現了很多新題,比如062 063題庫大更新
OCP解析公開課時間:【每周五晚8點】
OCP解析公開課地址:http://ke.qq.com/course/326223
OCP解析群資料分享:1015267481 驗證:ocp
-------------------------------------------------------
51題、choose one
The HR. DEPARTMENTS table is the parent of the HR. EMPLOYEES table. The EMPLOYEES .
DEPARTMENT_ID column has a foreign key constraint with the ON DELETE CASCADE option that refers to the DEPARTMENTS. DEPARTMENT_ID column. An index exists on the DEPARTMENTS. DEPARTMENT_ID column. A transaction deletes a primary key in the DEPARTMENTS table, which has child rows in the EMPLOYEES table.
Which statement is true?
A) The transaction acquires a table lock on the DEPARTMENTS table. This lock enables other sessions to query but not update the DEPARTMENTS table until the transaction on the DEPARTMENTS table is complete.
B) The transaction acquires a table lock on the EMPLOYEES table. This lock enables other sessions to query but not update the EMPLOYEES table until the transaction on the DEPARTMENTS table is complete.
C) Only the rows that are deleted in the DEPARTMENTS and EMPLOYEES tables are locked until the transaction on the DEPARTMENTS table is complete.
D) The transaction acquires a table lock only on the DEPARTMENTS table until the transaction is complete.
Answer:C
(解析:這道題的關鍵點就是ON DELETE CASCADE選項,如果把父表的主鍵刪除(注意這里不是刪除主鍵約束),那么子表相對應的行也會被刪除,所以在刪除父表主鍵的時候,子表
是被鎖住的,目的是同時要刪除子表對應的行。因為oracle刪除行時是基于行級的鎖。試驗證明是可以刪除其它子表上的行。)