Schemas

Use schemas in standard and external catalogs to organize data.

Catalogs are logical containers for schemas, which are also referred to as databases. Schemas can contain tables, which contain structured data, and volumes, which contain unstructured data.

When you create a standard catalog in the Master Catalog, a default schema is automatically created within it.

You can manage permissions to control who has access to your schema. For more information, see Schema Permissions.

The Master Catalog's default catalog, which is called 'default', contains a reserved schema named oci_ai_models. If you have the requisite permissions on OCI Generative AI models in the region, the model is displayed in the oci_ai_models schema and you can drag and drop the models onto a notebook to auto-generate code for batch inference. For more information, see OCI Generative AI (Pretrained Foundation Models).

You can't change the name of a schema in a standard catalog.

To share a schema, see Share Data.

Create a Schema

You can create a schema to organize tables and volumes in a catalog that you own or that's shared with you.

  1. Open the Create schema dialog.
    • From the left navigation pane:
      1. Click Create icon Create and select Schema.
      2. In the Select schema location dialog, select the catalog you want to create the schema for, and click Select.
    • From Master Catalog icon Master catalog:
      1. In the Master catalog tree or the Catalogs tab, click the catalog you want to create the schema for to open it.
      2. Click Create Schema.
  2. Enter a Schema name and Description.
  3. Click Create.

View Schema Details

You can view the details of a schema to review its configuration and metadata.

The Details tab for a schema displays the schema key and type, along with when and by whom the schema was created and last updated.

  1. In the left navigation pane, click Master Catalog icon Master catalog.
  2. In the Master catalog tree or the Catalogs tab, click the catalog that contains the schema you want to view.
  3. In the Schemas tab, click the schema to open it.
  4. Click Details.

    Schema page with Details tab highlighted and details displayed

Edit a Schema Description

You can modify the description for a schema if its contents or purpose has changed.

  1. In the left navigation pane, click Master Catalog icon Master catalog.
  2. In the Master catalog tree or the Catalogs tab, click the catalog that contains the schema you want to edit.
  3. In the Schemas tab, locate your schema and click Actions three dot icon Actions, then click Edit Description.

    Actions three-dot menu open for schema with Edit Description highlighted

  4. Edit the schema description and click Save.

Delete a Schema

You can delete a schema when it's no longer needed.

Note:

Deleting a schema also deletes all metadata and any AI Data Platform-managed data in managed tables and managed volumes associated with that schema. Make sure you back up or move any data you want to retain to another location before deleting a schema.
  1. In the left navigation pane, click Master Catalog icon Master catalog.
  2. In the Master catalog tree or the Catalogs tab, click the catalog that contains the schema you want to edit.
  3. In the Schemas tab, locate the schema you want to delete, click Actions three dot icon Actions, then click Delete.

    Actions three-dot menu open for schema with Delete highlighted

  4. Select Yes, force delete all associated data and metadata.

    Delete schema prompt is displayed with Yes, force delete all associated data and metadata selected and highlighted

  5. Click Delete.