nerdexam
Oracle

1Z0-007 · Question #9

Examine the structure if the EMPLOYEES table: You need to create a view called EMP_VU that allows the user to insert rows through the view. Which SQL statement, when used to create the EMP_VU view…

The correct answer is B. CREATE VIEW emp_Vu AS. This statement will create view that can be used to change tables in underlying table through simple views. It includes primary key, NOT NULL column and foreign key to avoid constraint Incorrect Answers A: This statement does not include JOB_ID column that cannot be NULL. In…

Creating and Managing Schema Objects

Question

Examine the structure if the EMPLOYEES table:

You need to create a view called EMP_VU that allows the user to insert rows through the view. Which SQL statement, when used to create the EMP_VU view, allows the user to insert rows?

Exhibit

1Z0-007 question #9 exhibit

Options

  • ACREATE VIEW emp_Vu AS
  • BCREATE VIEW emp_Vu AS
  • CCREATE VIEW emp_Vu AS
  • DCREATE VIEW emp_Vu AS

How the community answered

(40 responses)
  • A
    5% (2)
  • B
    78% (31)
  • C
    15% (6)
  • D
    3% (1)

Explanation

This statement will create view that can be used to change tables in underlying table through simple views. It includes primary key, NOT NULL column and foreign key to avoid constraint Incorrect Answers A: This statement does not include JOB_ID column that cannot be NULL. In general, all constraint restrictions defined on the underlying table also apply to modifying data via the view. For example, you can't add data to an underlying table via a view that violates the table's primary C: You cannot update a column of an underlying table if the simple view use a single-row function to define the column. D: You may not insert, update, or delete records data on the table underlying the simple view if the SELECT statement creating the view contains a GROUP BY clause, GROUP function, or DISTINCT clause.

Topics

#CREATE VIEW#DML through views#view insertability#view constraints

Community Discussion

No community discussion yet for this question.

Full 1Z0-007 Practice