Removes a schema with DROP SCHEMA. By default the schema must be
empty; cascade = TRUE drops its tables and views, and the schemas
nested inside it, with it. Like every change, the drop is a snapshot,
so the tables stay reachable through time travel.
Examples
lake_dir <- tempfile("dropschema_lake_")
dir.create(lake_dir)
attach_ducklake("dropschema_lake", lake_path = lake_dir)
create_schema("scratch")
#> Created schema "scratch".
create_table(mtcars, "scratch.cars")
drop_schema("scratch", cascade = TRUE)
#> Dropped schema "scratch".
detach_ducklake("dropschema_lake", shutdown = TRUE)
unlink(lake_dir, recursive = TRUE)
