Hour 17, "Improving Database Performance"

Quiz Answers

1: Would the use of a unique index on a small table be of any benefit?
A1: The index may not be of any use for performance issues; but, the unique index would keep referential integrity intact. Referential integrity is discussed in Hour 3, "Managing Database Objects."
2: What happens when the optimizer chooses not to use an index on a table when a query has been executed?
A2: A full table scan occurs.
3: Should the most restrictive clause(s) be placed before the join condition(s) or after the join conditions in the WHERE clause?
A3: The most restrictive clause(s) should be evaluated before the join condition(s) because join conditions normally return a large number of rows.

Exercise Answers ...

Get Sams Teach Yourself SQL in 24 Hours, Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.