Evaluate the following SQL statements:
You issue the following command to create a view that displays the IDs and last names of the
sales staff in the organization.
Which two statements are true regarding the above view? (Choose two.)
A.
It allows you to update job IDs of the existing sales staff to any other job ID in the EMPLOYEES
table
B.
It allows you to delete details of the existing sales staff from the EMPLOYEES table
C.
It allows you to insert rows into the EMPLOYEES table
D.
It allows you to insert IDs, last names, and job IDs of the sales staff from the view if it is used in
multitable INSERT statements
why the ans is B ?
why the answer is not C?
C is wrong because a NOT NULL column (DEPARTMENT_ID) is not part of the view.
Is this the only condition? Because there is WITH CHECK OPTION and this avoid insert rows other than job_id is “SA_”
https://docs.oracle.com/cd/E17952_01/refman-5.5-en/view-check-option.html
I am not sure if D is correct one. The command does not allow to insert data because a NOT NULL column (DEPARTMENT_ID) is not part of the view. The reason why D is incorrect is the same. It doesn’t matter if that is mutabile or not.
Please correct me if I am wrong. Thanks in advance.
multitable* -sorry for typo
@know: I suppose key statement in D is “from the view”. So the view is used here as a source of data.