Oracle Error ORA-30381: REWRITE_TABLE is not compatible with Oracle version

Oracle Error Message

ORA-30381: REWRITE_TABLE is not compatible with Oracle version

Reason for the Error

One or more column definitions in the REWRITE_TABLE is either missing or incompatible with the current Oracle version.

Solution

Connect to the appropriate schema, DROP TABLE REWRITE_TABLE and recreate it by invoking the admin/utlxrw.sql script prior to invoking the DBMS_MVIEW.EXPLAIN_REWRITE() API.