Move managed DLT table from one schema to another schema in Databricks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-09-2023 09:28 AM
I have a DLT table in schema A which is being loaded by DLT pipeline.
I want to move the table from schema A to schema B, and repoint my existing DLT pipeline to table in schema B. also I need to avoid full reload in DLT pipeline on table in Schema B.
Anybody had similar situation?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-10-2023 10:05 PM
This feature is being actively worked upon by our Engineers. The plan is to change the schema name in the DLT pipeline settings and DLT will move the managed DLT table to the other schema.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-21-2024 01:12 AM
Any updates on this since we are having this requirement
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-20-2025 02:35 AM
Any progress on this ?
Did you find a solution ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-20-2025 05:38 AM
Have you tried the below
- Pause or Stop the DLT Pipeline
- Prevent new writes while moving the table.
2.Move the Table in Metastore
DLT uses Delta tables under the hood, so you can move the table in the metastore without copying data:
ALTER TABLE schemaA.tableX
SET LOCATION 'abfss://container@storage/path/...tableX';
ALTER TABLE schemaA.tableX
RENAME TO schemaB.tableX;
SET LOCATION points to the existing Delta storage location for the new schema.
3. Update the DLT Pipeline
Edit the DLT pipeline code (or the pipeline notebook) to point to the new fully qualified table name @Dlt.table(
name="schemaB.tableX", # updated schema
comment="Moved from schemaA"
)
def tableX():
return dlt.read("schemaB.tableX")
4. Resume the DLT Pipeline
Start the pipeline
5. Verify
SELECT COUNT(*) FROM schemaB.tableX;
Let me know here if the above is effective