Querying Data with Transact-SQL — Question 190
Note: This question is part of a series of questions that present the same scenario. Each question in the series contains a unique solution that might meet the stated goals. Some question sets might have more than one correct solution, while others might not have a correct solution.
After you answer a question in this section, you will NOT be able to return to it. As a result, these questions will not appear in the review screen.
You are creating indexes in a data warehouse.
You have a dimension table named Table1 that has 10,000 rows. The rows are used to generate several reports.
The reports join a column that is the primary key.
The execution plan contains bookmark lookups for Table1.
You discover that the reports run slower than expected.
You need to reduce the amount of time it takes to run the reports.
Solution: You create a hash index on the primary key column.
Does this meet the goal?
Answer options
- A. Yes
- B. No
Correct answer: B
Explanation
Creating a hash index on the primary key column does not address the performance issue effectively because hash indexes are not suitable for range queries or ordered data retrieval, which are typically required for reports. Instead, a traditional B-tree index would be more appropriate for optimizing read performance on the primary key column and reducing execution time.