mc table register
The mc table register command registers an existing Iceberg table into the catalog.
Syntax
The command has the following syntax:
mc table register [FLAGS] ALIAS/WAREHOUSE/NAMESPACE/TABLE --metadata-location PATH
Flags
| Flag | Description |
|---|---|
--metadata-location value, -l value |
S3 path to an existing Iceberg metadata JSON file (required). |
--ignore-existing, -p |
Ignore if table already exists. |
Global flags
This command supports any of the global flags.
Examples
Register an existing table from a metadata file.
mc table register myminio/mywarehouse/prod/customers --metadata-location s3://mywarehouse/customers/metadata/00001.metadata.json
Register a table in a nested namespace.
mc table register myminio/analytics/sales/2024/orders --metadata-location s3://analytics/sales/2024/orders/metadata/v1.metadata.json
Register a table, ignoring if it already exists.
mc table register --ignore-existing myminio/mywarehouse/prod/customers --metadata-location s3://mywarehouse/customers/metadata/00001.metadata.json
Behavior
S3 compatibility
The mc command-line tool is built for compatibility with the AWS S3 API and is tested with MinIO AIStor and AWS S3 for expected functionality and behavior.