Unity Catalog Migrate
Disclaimer: This project is unofficial and not affiliated with or endorsed by the official Unity Catalog team.
Migrate catalogs, schemas, and tables from Databricks to Unity Catalog.
Requirements
- Python 3.9 or higher
- Databricks configuration file: https://docs.databricks.com/en/dev-tools/auth/config-profiles.html
Installation
To install the Unity Catalog Migrator, you can use the following commands:
pip install unitycatalog-migrate
Usage
Migrate Catalogs
ucm migrate-catalog NAMES... --profile <databricks-profile>
Migrate Schemas
ucm migrate-schema FULL_NAMES... --profile <databricks-profile>
where FULL_NAMES are in the format catalog.schema
Migrate Tables
ucm migrate-table FULL_NAMES.. --profile <databricks-profile>
where FULL_NAMES are in the format catalog.schema.table
Configuration
The Unity Catalog Migrator uses the following environment variables:
- UC_HOST_URL: The URL of the Unity Catalog server. Default is
http://localhost:8080/api/2.1/unity-catalog. - UC_TOKEN: The token to authenticate with the Unity Catalog server. Default is
None. You can also pass the token as an argument to the command.
Example
# Use Databricks CLI to get tables
table_names=$(databricks tables list catalog1 schema1 --profile DATABRICKS_TEST | awk 'NR>1 {print $1}' | paste -sd ' ' -)
# Migrate the tables to Unity Catalog using ucm
echo $table_names | xargs ucm migrate-table --profile DATABRICKS_TEST
Remarks
- Catalog and Schema need to exist in Unity Catalog before migrating tables
Not supported:
- system tables
- Variant datatype
Contributing
- Contributions are welcome. Please fork and make a PR and I'll take a look asap.
- Star the repo if you like it.
Metadata
Release files for unitycatalog-migrate 0.1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| unitycatalog_migrate-0.1.1.tar.gz | 84.0 kB | With provenance | Details for unitycatalog_migrate-0.1.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| unitycatalog_migrate-0.1.1-py3-none-any.whl | Python 3 | none | any | Details for unitycatalog_migrate-0.1.1-py3-none-any.whl |
Total release size: 91.5 kB
Release files / unitycatalog_migrate-0.1.1.tar.gz
| Download URL | unitycatalog_migrate-0.1.1.tar.gz |
|---|---|
| Size | 84.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
e2a5e81fec8692c5008271b90f5c893b7a7e6bd6f2fd3f999125ec73558b3a12
|
|
BLAKE2b-256 checksum How to use checksums |
a2c3acf1e87417c73715b0ba03c58f8314b41f8d8d981eeec1f9f2f1df3e5f3b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.12.8
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jan 27, 2025.
Transparency logRelease files / unitycatalog_migrate-0.1.1-py3-none-any.whl
| Download URL | unitycatalog_migrate-0.1.1-py3-none-any.whl |
|---|---|
| Size | 7.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
329a5a99f704df18aa4b5e4ae9493116326c0f444b9a1fb128b0c782b25ffe12
|
|
BLAKE2b-256 checksum How to use checksums |
7fe1ed8492115c31f2b896be02dc9dfc99ea01f08e083e64741599f5d929b793
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.12.8
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jan 27, 2025.
Transparency logSecurity for unitycatalog-migrate 0.1.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
Both files in this release have been uploaded with provenance metadata.
Attestation for unitycatalog_migrate-0.1.1.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jan 27, 2025.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.