[jOOQ/jOOQ#18824] Support CREATE CATALOG and DROP CATALOG

This commit is contained in:
Lukas Eder 2025-08-06 10:45:58 +02:00
parent 4a60e44d5e
commit 24e6a7b36d
2 changed files with 31 additions and 2 deletions

View File

@ -111,7 +111,19 @@ implements
}
private final void accept0(Context<?> ctx) {
ctx.visit(K_CREATE).sql(' ').visit(K_DATABASE);
ctx.visit(K_CREATE).sql(' ');
switch (ctx.family()) {
default:
ctx.visit(K_DATABASE);
break;
}
if (ifNotExists && supportsIfNotExists(ctx))
ctx.sql(' ').visit(K_IF_NOT_EXISTS);

View File

@ -111,12 +111,29 @@ implements
}
private void accept0(Context<?> ctx) {
ctx.visit(K_DROP).sql(' ').visit(K_DATABASE);
ctx.visit(K_DROP).sql(' ');
switch (ctx.family()) {
default:
ctx.visit(K_DATABASE);
break;
}
if (ifExists && supportsIfExists(ctx))
ctx.sql(' ').visit(K_IF_EXISTS);
ctx.sql(' ').visit(database);
}