DROP BRANCH¶
Remove a branch from a Lance table.
Spark Extension Required
This feature requires the Lance Spark SQL extension to be enabled. See Spark SQL Extensions for configuration details.
Overview¶
The DROP BRANCH command deletes a named branch reference from a Lance table. This removes the branch metadata entry, but does not rewrite data on main or on any other existing branch.
Syntax¶
Example¶
Output¶
The DROP BRANCH command returns:
| Column | Type | Description |
|---|---|---|
name |
String | The name of the dropped branch |
Notes and Limitations¶
DROP BRANCHis implemented as a Spark SQL extension command.- The target table must be a Lance table.
IF EXISTScan be used when dropping a branch conditionally.- Use SHOW BRANCHES to inspect existing branches before deleting one.