Documentation Index
Fetch the complete documentation index at: https://docs.turso.tech/llms.txt
Use this file to discover all available pages before exploring further.
DROP DOMAIN
Turso Extension: DROP DOMAIN is a Turso-specific statement not available in standard SQLite. This feature is experimental and must be enabled before use.
Syntax
Description
DROP DOMAIN removes the named domain from the database. The domain must exist unless theIF EXISTS clause is specified.
Clauses
| Clause | Description |
|---|---|
IF EXISTS | Suppresses the error that would occur if the domain does not exist. The statement is a no-op when the domain is not found. |
domain-name | The name of the domain to remove. |
Restrictions
A domain cannot be dropped while any table column uses it or while another domain references it as a base type. Remove all dependents before dropping.DROP DOMAIN vs DROP TYPE
DROP DOMAIN can only remove domains created with CREATE DOMAIN. Attempting to use DROP DOMAIN on a type created with CREATE TYPE results in an error, and vice versa.Examples
Drop a Domain
Drop with IF EXISTS
Drop After Removing Table Dependency
See Also
- CREATE DOMAIN for defining domains
- DROP TYPE for removing custom types