SQL query syntax
select grantee, null table_name, privilege from dba_sys_privs where grantee='SCOTT'
union all
select grantee, table_name, privilege from dba_tab_privs where grantee='SCOTT';
This query worked fine. No problem there.
However, I want to be able to input the grantee name every time I run the query. So I modified the query a little bit.
select grantee, null table_name, privilege from dba_sys_privs where grantee=&grantee
union all
select grantee, table_name, privilege from dba_tab_privs where grantee=&grantee;