(
scx: &StatementContext,
if_exists: bool,
name: &UnresolvedDatabaseName,
cascade: bool,
)
| 5380 | } |
| 5381 | |
| 5382 | fn plan_drop_database( |
| 5383 | scx: &StatementContext, |
| 5384 | if_exists: bool, |
| 5385 | name: &UnresolvedDatabaseName, |
| 5386 | cascade: bool, |
| 5387 | ) -> Result<Option<DatabaseId>, PlanError> { |
| 5388 | Ok(match resolve_database(scx, name, if_exists)? { |
| 5389 | Some(database) => { |
| 5390 | if !cascade && database.has_schemas() { |
| 5391 | sql_bail!( |
| 5392 | "database '{}' cannot be dropped with RESTRICT while it contains schemas", |
| 5393 | name, |
| 5394 | ); |
| 5395 | } |
| 5396 | Some(database.id()) |
| 5397 | } |
| 5398 | None => None, |
| 5399 | }) |
| 5400 | } |
| 5401 | |
| 5402 | pub fn describe_drop_objects( |
| 5403 | _: &StatementContext, |
no test coverage detected