AWR report in oracle
oracle
Solution
The user, you're using to generate AWR must not be having execute privileges on `DBMS_WORKLOAD_REPOSITORY` package.
To quote from Oracle Documentation,
..To invoke these procedures, a user must be granted the DBA role.
Here is the list of `GRANTS` you would need to generate AWR
GRANT SELECT ON SYS.V_$DATABASE TO MY_USER;
GRANT SELECT ON SYS.V_$INSTANCE TO MY_USER;
GRANT EXECUTE ON SYS.DBMS_WORKLOAD_REPOSITORY TO MY_USER;
GRANT SELECT ON SYS.DBA_HIST_DATABASE_INSTANCE TO MY_USER;
GRANT SELECT ON SYS.DBA_HIST_SNAPSHOT TO MY_USER;
GRANT ADVISOR TO MY_USER;
Problem
I am trying the generate AWR report in oracle 11G. At the creation time, i am getting some error message. error is mentioned below Using the report name awrrpt_1_2504_2709.html. select output from table(dbms_workload_repository.awr_report_html( :dbid, * ERROR at line 1: ORA-00904: : invalid identifier Steps that i am using for generate the AWR reports @$ORACLE_HOME/rdbms/admin/awrrpt.sql Enter value for report_type: html Enter value for begin_snap: 2504 Begin Snapshot Id specified: 2504 Enter value for end_snap: 2709 End Snapshot Id specified: 2709 Please help me on this.