ORA-1031 Returned During ALTER TABLE SYS.AUD_LOAD EXCHANGE PARTITION Command With DB Vault Enabled. (Doc ID 2226980.1)

Last updated on FEBRUARY 02, 2017

Applies to:

Oracle Database - Enterprise Edition - Version 12.1.0.2 and later
Information in this document applies to any platform.

Goal

In a 12.1.0.2 database with Oracle Database Vault enabled, our audit management process is trying to execute the following SQL stmt from a stored procedure.

ALTER TABLE SYS.AUD_LOAD EXCHANGE PARTITION audit_all WITH TABLE SYS.AUD$ WITHOUT VALIDATION UPDATE INDEXES;

This statement returns ORA-1031 when executed from a stored procedure, but is successful when executed from SQL*Plus. The statement also executes successfully when DB Vault is disabled. However, tt executes successfully in other databases where DB Vault is enabled. The user has participant authorization to the "Oracle System Privilege and Role Management Realm".

The executing user and owner of the stored procedure have SELECT and ALTER privileges on the SYS.AUD_LOAD table granted directly, instead of through a role.

How can we determine what other privilege is needed that causes the ORA-1031 error when the statement is executed from a stored procedure?
 

Solution

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms