Skip to end of metadata
Go to start of metadata
  • get DBID, Instance number, and range of snapshots for AWR report

    select * from dba_hist_snapshot;
  • For text report:

    select output from table(dbms_workload_repository.awr_report_text(DBID,INSTNUM,SNAPSTART,SNAPSTOP));
  • For HTML report:

    select output from table(dbms_workload_repository.awr_report_html(DBID,INSTNUM,SNAPSTART,SNAPSTOP));

(spool to file, if applicable)