You are logged in as the HR user and you execute the following procedure:
SQL > exec DBMS_STATS.SET_TABLE_PREFS (‘HR’, ‘EMPLOYEES’, ‘PUBLISH’, ‘FALSE’);
SQL> exec DBMS_STATS.GATHER_TABLE_STATS (‘HR’, ‘EMPLOYEES’);
Which statement is true about the newly gathered statistics?
A.
They are temporary and purged when the session exits.
B.
They are used by the optimizer for all sessions.
C.
They are locked and cannot be overwritten.
D.
They are marked as pending and stored in the pending statistics table.
Explanation:
In previous database versions, new optimizer statistics were automatically published
when they were gathered. In 11g this is still the default action, but you now have the option of
keeping the newly gathered statistics in a pending state until you choose to publish them.
The DBMS_STATS.GET_PREFS function allows you to check the ‘PUBLISH’ attribute to see if
statistics are automatically published. The default value of TRUE means they are automatically
published, while FALSE indicates they are held in a pending state.
Reference: Statistics Collection Enhancements in Oracle Database 11g Release 1, Pending
Statistics
I think D