3.3.3.1 Creation of Application PDB
A PDB that is plugged in to an application container can be created from application seed through cloning.
Below script will be used to create Application PDB from Application Seed. DBA rights are required to perform this step.
(Refer the Attachment panel of this document to view the script)
CDB Name | FC142CDB |
CDB Schema User Name | Sys |
CDB Schema Password | Sys |
CDB HOST | 1.1.1.1 |
CDB PORT | 1522 |
CDB Mounted Path | /scratch/db1800dat |
Application Root Name | FCAPPROOT |
Application PDB Name | FCAPPPDB1 |
Note for Shared Application and User Authentication deployment model before object conversion:
- Application root before object conversion will only have the static data.
- If the data import has to be done to the application root schema, following steps 3 to 8 has to be carried out.
- Triggers have to be disabled in the respective schemas before initiating the import.
- Tables which are going to be available in the Application root as part of this model can be identified with the below query. (Total of around 21 tables)
SELECT DISTINCT
a.object_name
FROMcstm_approot_objects a
WHEREsharing = 'DL'
ANDUPPER(object_type) = 'TABLE'
AND EXISTS (SELECT1
FROMuser_objects b
WHEREb.object_name = a.object_name
ANDb.object_type = 'TABLE')
AND EXISTS (SELECT1
FROMcstm_approot_functions_menu c
WHEREc.function_id = a.function_id
ANDc.modifiable = 'S');
- The export data dump taken from the entities has to be imported into the application root schema only for these above set of tables.
- For the PDB’s, data from the entities can be directly imported into the respective application PDBs.
- Once the import is completed, triggers have to be enabled again in the schemas.
- After the data import, object conversion will be done from the installer.
Example
If there are two entity schemas available for India and Japan region and we have two export dump taken for these schemas.
- Step 1: Importing data into the Application root schema
- Import the dump taken from India entity schema for the given list of tables followed by the import of dump from Japan entity schema for the same list of tables.
- Step 2: Importing data into the Application PDB schema
- Once the first Application PDB is created from the application seed which will have only the data for static INCs, import the full dump taken from India entity schema.
- Note for Shared Application and Shared Data – Default deployment model before object conversion:
- Identified list of entities will be available in approot and sharing of entities from Approot to individual PDBs is applicable in this model.
- Application root before object conversion will only have the static data.
- If the data import has to be done to the application root/ schema, following steps 3 to 8 has to be carried out.
- Triggers have to be disabled in the respective schemas before initiating the import.
- Tables which are going to be available in the Application root as part of this model can be identified with the below query. (Total of around 464 tables)
SELECT DISTINCT
a.object_name
FROMcstm_approot_objects a
WHEREsharing = 'DL'
ANDUPPER(object_type) = 'TABLE'
AND EXISTS (SELECT1
FROMuser_objects b
WHEREb.object_name = a.object_name
ANDb.object_type = 'TABLE')
AND EXISTS (SELECT1
FROMcstm_approot_functions_menu c
WHERE(c.function_id = a.function_id
OR
a.function_id
IN('STATIC', 'DYNAMIC')));
- The export data dump taken from the entities has to be imported into the application root schema only for these above set of tables.
- For the PDB’s, data from the entities can be directly imported into the respective application PDBs.
- Once the import is completed, triggers have to be enabled again in the schemas.
- After the data import, object conversion will be done from the installer.
Example
If there are two entity schemas available for India and Japan region and we have two export dump taken for these schemas.
- Step 1: Importing data into the Application root schema
- Import the dump taken from India entity schema for the given list of tables followed by the import of dump from Japan entity schema for the same list of tables.
- Note for Shared Application and Shared Data – Default deployment model before object conversion:
- Identified list of entities will be available in approot and sharing of entities from Approot to individual PDBs is applicable in this model.
- Application root before object conversion will only have the static data.
- If the data import has to be done to the application root/ schema, following steps 3 to 8 has to be carried out.
- Triggers have to be disabled in the respective schemas before initiating the import.
- Tables which are going to be available in the Application root as part of this model can be identified with the below query. (Total of around 464 tables)
SELECT DISTINCT
a.object_name
FROMcstm_approot_objects a
WHEREsharing = 'DL'
ANDUPPER(object_type) = 'TABLE'
AND EXISTS (SELECT1
FROMuser_objects b
WHEREb.object_name = a.object_name
ANDb.object_type = 'TABLE')
AND EXISTS (SELECT1
FROMcstm_approot_functions_menu c
WHERE(c.function_id = a.function_id
OR
a.function_id
IN('STATIC', 'DYNAMIC')));
- The export data dump taken from the entities has to be imported into the application root schema only for these above set of tables.
- For the PDB’s, data from the entities can be directly imported into the respective application PDBs.
- Once the import is completed, triggers have to be enabled again in the schemas.
- After the data import, object conversion will be done from the installer.
Example
If there are two entity schemas available for India and Japan region and we have two export dump taken for these schemas.
- Step 1: Importing data into the Application root schema
- Import the dump taken from India entity schema for the given list of tables followed by the import of dump from Japan entity schema for the same list of tables.
- Step 2: Importing data into the Application PDB schema
- Once the first Application PDB is created from the application seed which will have only the data for static INCs, import the full dump taken from India entity schema
Parent topic: Steps for Application Setup When Transaction Data Exists