Create Schema

Create new schemas in Airport-attached databases using standard SQL CREATE SCHEMA statements with Arrow Flight server integration.

The Airport extension supports creating schemas in attached databases. DuckDB schemas can contain tables, functions, macros, and other database objects. The Arrow Flight server determines whether the schema creation request is permitted.

Example

For a DuckDB session to create a schema, a standard SQL CREATE SCHEMA statement while referencing a database/catalog that is managed by the Airport extension.

-- Attach an Airport database
ATTACH 'example' (TYPE AIRPORT, location 'grpc://localhost:50312/');

-- Create a new schema called main in the
-- example catalog
CREATE SCHEMA example.main;

Arrow Flight Server Implementation Notes

The Airport extension will perform a DoAction Arrow Flight RPC with a method name of create_schema.