Oracle Database 12c: Advanced Administration — Question 161

You want to capture column group usage and gather extended statistics for better cardinality estimates for the customers table in the SH schema.
Examine the following steps:
1. Issue the SELECTDBMS_STATS. CREATE_EXTENDED_STATS(SH, 'CUSTOMERS')from dual statement.
2.Execute the dbms_stats.seed_col_usage (null,SH,500) procedure.
3.Execute the required queries on the customers table.
4.Issue the select dbms_stats.reportwcol_usage(SH, 'customers') from dual statement.
Identify the correct sequence of steps.

Answer options

Correct answer: B

Explanation

The correct sequence is B, which starts with executing dbms_stats.seed_col_usage to gather column usage data before running any queries on the customers table. After querying, the report on column usage can be generated, followed by creating the extended statistics. The other options either start with querying before the necessary setup or misplace the order of reporting and creating statistics.