In set operations that
use the operators EXCEPT, INTERSECT, or UNION, and no keyword, columns
are overlaid based on their position in the SELECT clause. It does
not matter whether the overlaid columns have the same name. When columns
are overlaid, the column name is taken from the first table that is
specified in the SELECT clause.
Correct answer: d
By default, when processing
a set operation that contains the EXCEPT, INTERSECT, and UNION set
operators, PROC SQL makes an extra pass through the data to eliminate
duplicate rows. The keyword ALL is used to suppress that additional
pass through the tables, allowing duplicate rows to appear in the
result set. Because the OUTER UNION set operator displays all rows,
the keyword ALL is invalid and cannot be used with OUTER UNION.
Correct answer: d
The output contains
all rows that are unique in the combined set of rows from both tables,
and the columns have been overlaid by position. This output is generated
by a set operation that uses the set operator UNION without keywords.
Correct answer: a
The PROC SQL set operation
that uses the set operator OUTER UNION without a keyword is the only
code shown that does not overlay any columns in output.
Correct answer: a
The keyword CORR (CORRESPONDING)
can be used alone or together with the keyword ALL.
Correct answer: b
This PROC SQL output
includes all rows from the table Pets that do not appear in the table
Dogs. No duplicates are displayed. A PROC SQL set operation that contains
the set operator EXCEPT without keywords produces these results.
Correct answer: b
The set operator EXCEPT
returns all the rows in the first table that do not appear in the
second table. The keyword ALL suppresses the extra pass that PROC
SQL makes through the data to eliminate duplicate rows. The EXCEPT
operator when used alone also produces the output that is specified
in the question.
Correct answer: c
The set operator UNION
returns all rows that are unique in the combined set of rows from
both tables.
Correct answer: c
The set operator INTERSECT
returns all rows that are common to both tables. Specifying the keyword
ALL suppresses PROC SQL's additional pass through the data to eliminate
duplicate rows.