Home > Oracle Application Express ... > Creating Workspaces > Managing Workspace to Schem...
When users log in to Oracle Application Express, they log in to a shared work area called a workspace. Each workspace can have multiple associated (or mapped) schemas. By associating a workspace with a schema, developers in that workspace can:
Build applications that interact with the database objects in that schema.
Create new database objects in that schema.
Topics:
Viewing Schema and Workspace Assignments in a Development Environment
Viewing Schema and Workspace Assignments in a Runtime Environment
Removing a Schema Mapping from a Workspace in a Runtime Environment
Oracle Application Express administrators can view the existing schema to workspace assignment on the Manage Workspace to Schema Assignments page.
To view the existing schema to workspace assignment:
Log in to Oracle Application Express Administration Services. See "Logging in to Oracle Application Express Administration Services".
Click Manage Workspaces.
Under Manage Workspaces, click Manage Workspace to Schema Assignments.
The Manage Workspace to Schema Assignments page appears. It lists all workspaces in your environment along with its most recently associated schema. Note that only one schema appears for each workspace in this list.
Tip: You can view all schemas associated with a workspace on the Workspace home page or by viewing the Workspace Details report. See "Viewing Workspace Details". |
To view the existing schema to workspace assignment in a runtime environment:
Start SQL*Plus and connect to the database where Oracle Application Express is installed as SYS
. For example:
On Windows:
SYSTEM_DRIVE:\ sqlplus /nolog
connect sys as sysdba
On UNIX and Linux:
$ sqlplus /nolog connect sys as sysdba
When prompted enter the appropriate password.
Run the following statement:
ALTER SESSION SET CURRENT_SCHEMA = FLOWS_030100
Run the following statement:
SELECT APEX_INSTANCE_ADMIN.GET_SCHEMAS(WORKSPACE_NAME)
FROM DUAL;
Where WORKSPACE_NAME
is the name of the workspace.
To edit an existing schema and workspace assignment:
Log in to Oracle Application Express Administration Services. See "Logging in to Oracle Application Express Administration Services".
Click Manage Workspaces.
Under Manage Workspaces, click Manage Workspace to Schema Assignments.
The Manage Workspace to Schema Assignments page appears.
To edit an existing workspace to schema assignment:
Select the workspace name.
The Edit Schema to Workspace Assignment page appears.
Select a new workspace or schema.
Click Apply Changes.
Oracle Application Express administrators can associate (or map) additional existing schemas to a workspace.
To associate additional schemas with a workspace:
Log in to Oracle Application Express Administration Services. See "Logging in to Oracle Application Express Administration Services".
Click Manage Workspaces.
Under Manage Workspaces, click Manage Workspace to Schema Assignments.
The Manage Workspace to Schema Assignments page appears.
Click Create.
The Add Schema wizard appears.
For New or Existing Schema, select Existing and click Next.
Follow the on-screen instructions to associate the existing schema to a workspace.
To verify that the new schema is added to the workspace:
Log in to the workspace on Oracle Application Express.
Review the Workspace Schemas list on the Workspace home page. The list shows all schemas currently associated with this workspace.
To associate additional schemas with a workspace in a runtime environment:
Start SQL*Plus and connect to the database where Oracle Application Express is installed as SYS
. For example:
On Windows:
SYSTEM_DRIVE:\ sqlplus /nolog
connect sys as sysdba
On UNIX and Linux:
$ sqlplus /nolog connect sys as sysdba
When prompted enter the appropriate password.
Run the following statement:
ALTER SESSION SET CURRENT_SCHEMA = FLOWS_030100
Run the following statement:
BEGIN APEX_INSTANCE_ADMIN.ADD_SCHEMA(WORKSPACE_NAME, SCHEMA_NAME) END;
Where:
WORKSPACE_NAME
is the name of the workspace.
SCHEMA_NAME
is the name of the schema.
To remove a schema mapping from a workspace in a runtime environment:
Start SQL*Plus and connect to the database where Oracle Application Express is installed as SYS
. For example:
On Windows:
SYSTEM_DRIVE:\ sqlplus /nolog
connect sys as sysdba
On UNIX and Linux:
$ sqlplus /nolog connect sys as sysdba
When prompted enter the appropriate password.
Run the following statement:
ALTER SESSION SET CURRENT_SCHEMA = FLOWS_030100
Run the following statement:
BEGIN APEX_INSTANCE_ADMIN.REMOVE_SCHEMA(WORKSPACE_NAME, SCHEMA_NAME) END;
Where:
WORKSPACE_NAME
is the name of the workspace.
SCHEMA_NAME
is the name of the schema.
Oracle Application Express administrators can create a new schema and associate it with a workspace.
To create a new schema for a workspace:
Log in to Oracle Application Express Administration Services. See "Logging in to Oracle Application Express Administration Services".
Click Manage Workspaces.
Under Manage Workspaces, click Manage Workspace to Schema Assignments.
The Manage Workspace to Schema Assignments page appears.
Click Create.
The Add Schema wizard appears.
For New or Existing Schema, select New and click Next.
For Choose Workspace, select the workspace that you want to associate the new schema with and click Next.
For Identify Schema:
Schema - Enter a unique name containing only letters.
Tip: To verify that the new schema name is unique, open the select list and search for the name. |
Password - Enter a case-sensitive password.
Default Tablespace - Identify the default tablespace that you want this schema to use.
Temporary Tablespace - Identify the temporary tablespace you want this schema to use.
Click Next.
Confirm the information and click Add Schema.
To verify that the new schema is added to the workspace:
Log in to the workspace on Oracle Application Express.
Review the Workspace Schemas list on the Workspace home page. The list shows all schemas associated with this workspace.