mc table share create

The mc table share create command creates a new Delta Sharing configuration on a MinIO AIStor cluster.

A share configuration defines a named collection of tables that can be accessed by external consumers through Delta Sharing tokens.

The following command creates a share named analytics-share with a Delta table on the myaistor MinIO AIStor cluster:

mc table share create myaistor/analytics-share default \
    "sales:delta:data-bucket:/delta/sales/"

The command has the following syntax:

mc [GLOBALFLAGS] table share create       \
                 ALIAS/SHARE              \
                 SCHEMA                   \
                 TABLE [TABLE ...]        \
                 [--description "STRING"]
  • Brackets [] indicate optional parameters.
  • Parameters sharing a line are mutually dependent.
  • Parameters separated using the pipe | operator are mutually exclusive.

Copy the example to a text editor and modify as-needed before running the command in the terminal/shell.

Parameters

ALIAS

Required

The alias of a MinIO AIStor cluster on which to create the share.

SHARE

Required

The name for the new share configuration.

SCHEMA

Required

The schema name within the share to contain the table.

TABLE

Required

One or more table specifications to add to SCHEMA. Specify multiple space-separated table specifications to add several tables to the same schema in a single invocation. This removes the need for a follow-up mc table share update --add command when all tables belong to the same schema. A table name that appears more than once in the command is rejected.

Each table specification uses one of the following formats:

TypeFormatDescription
DeltaNAME:delta:BUCKET:PATHA Delta Lake table stored in object storage.
IcebergNAME:uniform:WAREHOUSE:NAMESPACE:TABLEAn Iceberg table in an AIStor Tables warehouse.

Delta table fields:

  • NAME - Table name as seen by share consumers
  • BUCKET - Bucket containing the Delta table
  • PATH - Path to the Delta table within the bucket

Iceberg table fields:

  • NAME - Table name as seen by share consumers
  • WAREHOUSE - Bucket containing Iceberg warehouse metadata
  • NAMESPACE - Database or schema name in the Iceberg catalog
  • TABLE - Table name in the Iceberg catalog

--description

Optional

A description for the share configuration.

Global flags

This command supports any of the global flags.

Examples

Create a share with a Delta table

Use mc table share create to create a share with a Delta Lake table:

mc table share create ALIAS/SHARE SCHEMA "NAME:delta:BUCKET:PATH"
  • Replace ALIAS with the alias of the MinIO AIStor cluster.
  • Replace SHARE with the name for the new share.
  • Replace SCHEMA with the schema name within the share.
  • Replace NAME with the table name consumers will see.
  • Replace BUCKET with the bucket containing the Delta table.
  • Replace PATH with the path to the Delta table.

Create a share with an Iceberg table

Use mc table share create to create a share with an Iceberg table:

mc table share create myaistor/catalog-share public \
    "orders:uniform:warehouse-bucket:tpch:orders" \
    --description "TPC-H orders"

Create a share with description

Use the --description flag to add a description:

mc table share create myaistor/analytics-share default \
    "sales:delta:data-bucket:/delta/sales/" \
    --description "Analytics data share for BI team"

Create a share with multiple tables

Specify several space-separated table specifications to add multiple tables to the same schema in a single command:

mc table share create myaistor/analytics-share default \
    "sales_data:delta:data-bucket:/delta/sales/" \
    "orders_tbl:uniform:warehouse-bucket:tpch_namespace:orders" \
    --description "Sales and orders share"

On this page