Oracle DBMS_AWR_ANALYTICS
Version 21c

General Information
Library Note Morgan's Library Page Header
Which has the higher priority in your organization: Deploying a new database or securing the ones you already have? Looking for a website, and resources, dedicated solely to securing Oracle databases? Check out DBSecWorx.
Purpose Creates support log based replication (proj 17779) used for analytic functions. Reads existing AWR data accessible through views and tables generating no UNDO/REDO and can be replicated.
AUTHID DEFINER
Dependencies
DBMS_AWR_ANALYTICS_LIB    
Documented No
First Available 20c
Pragma PRAGMA SUPPLEMENTAL_LOG_DATA(default, READ_ONLY);
Security Model Owned by SYS with EXECUTE granted to the DBA role.
Source {ORACLE_HOME}/rdbms/admin/dbmsawr.sql
 
GENERATE_REPORT (new 20c)
Presumably generates an AWR Analytics Report if the feature is enabled dbms_awr_analytics.generate_report(
dbid     IN NUMBER,
beg_snap IN NUMBER,
end_snap IN NUMBER,
format   IN VARCHAR2 DEFAULT 'HTML',
options  IN CLOB     DEFAULT NULL)
RETURN CLOB;
SELECT dbid FROM v$database;

      DBID
----------
1939439852



SELECT MAX(snap_id)-12 AS BEG_SNAP_ID, MAX(snap_id)-1 AS END_SNAPID
FROM dba_hist_snapshot;

BEG_SNAP_ID END_SNAPID
----------- ----------
        340        351


DECLARE
 retVal CLOB;
BEGIN
  retVal := dbms_awr_analytics.generate_report(2140826538, 340, 351, 'TEXT', RetVal);
  dbms_output.put_line(retVal);
END;
/
DECLARE
*
ERROR at line 1:
ORA-15900: AWR Analytics operation failed: feature is disabled
ORA-06512: at "SYS.DBMS_AWR_ANALYTICS", line 3
ORA-06512: at "SYS.DBMS_AWR_ANALYTICS", line 44
ORA-06512: at line 4

Related Topics
Built-in Functions
Built-in Packages
Database Security
AWRINFO_UTIL
AWR Report
DBMS_AWR_REPORT_LAYOUT
What's New In 19c
What's New In 20c-21c

Morgan's Library Page Footer
This site is maintained by Dan Morgan. Last Updated: This site is protected by copyright and trademark laws under U.S. and International law. © 1998-2021 Daniel A. Morgan All Rights Reserved
  DBSecWorx