I am trying to use the DBMS_STATS Reporting Functions and getting this “ORA-20000: Insufficient privileges” error.
SQL> select dbms_stats.report_single_stats_operation(opid => 100784, detail_level => 'TYPICAL', format => 'TEXT') text_line from dual;
TEXT_LINE
<report>ORA-20000: Insufficient privileges</report>
I can run the dbms_stats.gather_table_stats successfully but not the dbms_stats.report_single_stats_operation. The account have “analyze any” privileges. What could I be missing. Please advise.
Thank you,
Warren