[#6474] Support anonymous blocks in SQL Server
This commit is contained in:
parent
180f8bf688
commit
39977aaa5b
@ -52,7 +52,6 @@ import static org.jooq.impl.Keywords.K_EXECUTE_BLOCK;
|
||||
import static org.jooq.impl.Keywords.K_EXECUTE_IMMEDIATE;
|
||||
import static org.jooq.impl.Keywords.K_EXECUTE_STATEMENT;
|
||||
import static org.jooq.impl.Keywords.K_NOT;
|
||||
import static org.jooq.impl.Keywords.K_NULL;
|
||||
import static org.jooq.impl.Tools.decrement;
|
||||
import static org.jooq.impl.Tools.increment;
|
||||
import static org.jooq.impl.Tools.DataKey.DATA_BLOCK_NESTING;
|
||||
@ -152,6 +151,7 @@ final class BlockImpl extends AbstractQuery implements Block {
|
||||
|
||||
|
||||
|
||||
|
||||
default: {
|
||||
accept0(ctx);
|
||||
break;
|
||||
@ -177,6 +177,7 @@ final class BlockImpl extends AbstractQuery implements Block {
|
||||
|
||||
|
||||
|
||||
|
||||
case FIREBIRD:
|
||||
case MARIADB:
|
||||
default:
|
||||
|
||||
@ -37,6 +37,10 @@
|
||||
*/
|
||||
package org.jooq.impl;
|
||||
|
||||
import static org.jooq.impl.DSL.falseCondition;
|
||||
import static org.jooq.impl.DSL.one;
|
||||
import static org.jooq.impl.DSL.select;
|
||||
import static org.jooq.impl.Keywords.K_IF;
|
||||
import static org.jooq.impl.Keywords.K_NULL;
|
||||
|
||||
import org.jooq.Clause;
|
||||
@ -50,11 +54,24 @@ final class NullStatement extends AbstractStatement {
|
||||
/**
|
||||
* Generated UID
|
||||
*/
|
||||
private static final long serialVersionUID = -1065054646570980726L;
|
||||
private static final long serialVersionUID = -1065054646570980726L;
|
||||
static final NullStatement INSTANCE = new NullStatement();
|
||||
|
||||
@Override
|
||||
public final void accept(Context<?> ctx) {
|
||||
ctx.visit(K_NULL);
|
||||
switch (ctx.family()) {
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
default:
|
||||
ctx.visit(K_NULL);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Loading…
Reference in New Issue
Block a user