Consider an INSERT statement that inserts tuples into table T and that contains a nested SELECT statement having predicate P in its WHERE clause. Assume P is a simple predicate that does not contain a nested SELECT statement and consists of a conjunction of clauses of the form (Attribute op constant). Describe the predicate associated with T.
What will be an ideal response?
Let P’ is the predicate associated with T. A subset of the attributes named in P
are associated with attributes of T through the SELECT list of the nested SELECT
statement and the attribute list of the INSERT statement. Let A be such an attribute
and let A’ be the corresponding attribute of T. Then the conjunct of P describing A is
a conjunct of P’ with A’ substituted for A. Furthermore, if the schema for T specifies a
default value, def , for an attribute, B, not contained in the attribute list of the INSERT
statement, P’ contains a conjunct (B = ’def ’).
You might also like to view...
A(n) ____ is a group of commands, or items, presented in a list.
A. action list B. input box C. menu D. status bar
A page's middle directory contains a pointer to the actual page frame.
Answer the following statement true (T) or false (F)