RE: Drawing a blank and can't find a quick answer - view for incremental stats enabled tables?

  • From: TJ Kiernan <tkiernan@xxxxxxxxxxx>
  • To: "christopherdtaylor1994@xxxxxxxxx" <christopherdtaylor1994@xxxxxxxxx>, ORACLE-L <oracle-l@xxxxxxxxxxxxx>
  • Date: Wed, 21 Mar 2018 15:31:26 +0000

Use the DBMS_STATS function against DBA_TAB_PARTITIONS, like this…

COL TABLE_OWNER FORMAT A10
COL TABLE_NAME FORMAT A30
COL INCREMENTAL FORMAT A10
SELECT DISTINCT TABLE_OWNER,
       TABLE_NAME,
       DBMS_STATS.GET_PREFS('INCREMENTAL',TABLE_OWNER, TABLE_NAME) AS 
INCREMENTAL
  FROM DBA_TAB_PARTITIONS
 WHERE TABLE_OWNER IN ('<SCHEMS_YOU_CARE_ABOUT>')
 ORDER BY 1,2
;

HTH,
T. J.

From: oracle-l-bounce@xxxxxxxxxxxxx [mailto:oracle-l-bounce@xxxxxxxxxxxxx] On ;
Behalf Of Chris Taylor
Sent: Wednesday, March 21, 2018 9:59 AM
To: ORACLE-L <oracle-l@xxxxxxxxxxxxx>
Subject: Drawing a blank and can't find a quick answer - view for incremental 
stats enabled tables?

​Is there a system view that shows which tables INCREMENTAL stats have been 
setup on?

I know I can do:
DBMS_STATS.get_prefs and pass in the table table and owner but surely there's a 
view that I can query?

But I can't find it - we're on 12.1.0.2.

Thanks,
Chris​

Other related posts: