Which two statements regarding the EMP_ID_SEQ sequence are true?

Examine the structure of the EMPLOYEES table:
EMPLOYEE_ID NUMBER NOT NULL, Primary Key
EMP_NAME VARCHAR2(30)
JOB_ID NUMBER\
SAL NUMBER
MGR_ID NUMBER References EMPLOYEE_ID column
DEPARTMENT_ID NUMBER Foreign key to DEPARTMENT_ID column of theDEPARTMENTS
table
You created a sequence called EMP_ID_SEQ in order to populate sequential values for the
EMPLOYEE_ID column of the EMPLOYEES table.
Which two statements regarding the EMP_ID_SEQ sequence are true? (Choose two.)

Examine the structure of the EMPLOYEES table:
EMPLOYEE_ID NUMBER NOT NULL, Primary Key
EMP_NAME VARCHAR2(30)
JOB_ID NUMBER\
SAL NUMBER
MGR_ID NUMBER References EMPLOYEE_ID column
DEPARTMENT_ID NUMBER Foreign key to DEPARTMENT_ID column of theDEPARTMENTS
table
You created a sequence called EMP_ID_SEQ in order to populate sequential values for the
EMPLOYEE_ID column of the EMPLOYEES table.
Which two statements regarding the EMP_ID_SEQ sequence are true? (Choose two.)

A.
You cannot use the EMP_ID_SEQ sequence to populate the JOB_ID column.

B.
The EMP_ID_SEQ sequence is invalidated when you modify the EMPLOYEE_ID column.

C.
The EMP_ID_SEQ sequence is not affected by modifications to the EMPLOYEES table.

D.
Any other column of NUMBER data type in your schema can use the EMP_ID_SEQ sequence.

E.
The EMP_ID_SEQ sequence is dropped automatically when you drop the EMPLOYEES table.

F.
The EMP_ID_SEQ sequence is dropped automatically when you drop the EMPLOYEE_ID
column.

Explanation:
the EMP_ID_SEQ sequence is not affected by modification to the EMPLOYEES
table. Any other column of NUMBER data type in your schema can use the EMP_ID_SEQ
sequence.
Incorrect answer:
AEMP_ID_SEQ sequence can be use to populate JOB_ID
BEMP_ID_SEQ sequence will not be invalidate when column in EMPLOYEE_ID is modify.
EEMP_ID_SEQ sequence will be dropped automatically when you drop the EMPLOYEES table.
FEMP_ID_SEQ sequence will be dropped automatically when you drop the EMPLOYEE_ID
column.
Refer: Introduction to Oracle9i: SQL, Oracle University Study Guide, 12-4



Leave a Reply 4

Your email address will not be published. Required fields are marked *


Bina

Bina

The table is wrong. You don’t use not null and primary key in the same column as constraint. Primary key cover not null and uniqueness.

riccia

riccia

I agree, i seems that it’s a mistake

Sagar

Sagar

You can do that (mark a column Not Null & Primary Key) while creating a table. So it’s not an issue.

eJossue

eJossue

You’re right!