Error ORA-65040 During Registry$sqlpatch Recreation at PDB Level
(Doc ID 3036374.1)
Last updated on JULY 21, 2024
Applies to:
Oracle Database - Enterprise Edition - Version 19.3.0.0.0 and laterOracle Cloud Infrastructure - Exadata Cloud Service - Version N/A to N/A [Release N/A]
Gen 1 Exadata Cloud at Customer (Oracle Exadata Database Cloud Machine) - Version N/A to N/A
Gen 2 Exadata Cloud at Customer - Version N/A to N/A [Release All Releases]
Information in this document applies to any platform.
Goal
To recreate registry$sqlpatch at the PDB level for syncing patch versions and ensuring successful execution of datapatch.
1. Set Container to PDB:
SQL> alter session set container=PDB_NAME;
This command sets the session to the specified PDB.
2. Backup registry$sqlpatch Table:
SQL> create table registry$sqlpatch_PDB as select * from registry$sqlpatch;
This command creates a backup of the registry$sqlpatch table in the PDB.
3. Drop registry$sqlpatch Table:
This command drops the registry$sqlpatch table.
4. Recreate registry$sqlpatch Table:
This command runs the script to recreate the registry$sqlpatch table.
5. Execute Datapatch in Upgrade Mode:
SQL> alter pluggable database PDB_NAME open upgrade;
Issue Encountered:
While attempting to drop the registry$sqlpatch table, the following error occurs:
SQL> drop table registry$sqlpatch;
drop table registry$sqlpatch
*
ERROR at line 1:
ORA-65040: operation not allowed from within a pluggable database
The error ORA-65040
indicates that the operation is not allowed from within a pluggable database. This suggests that the drop table command for registry$sqlpatch cannot be executed directly within the PDB context.
Solution
To view full details, sign in with your My Oracle Support account. |
|
Don't have a My Oracle Support account? Click to get started! |
In this Document
Goal |
While attempting to drop the registry$sqlpatch table, the following error occurs: |
Solution |