[jOOQ/jOOQ#8640] Don't throw an exception for SEQ.CURRVAL in Derby

This commit is contained in:
Lukas Eder 2022-02-11 14:10:36 +01:00
parent 1f1831fbcd
commit 2b67cabc2c

View File

@ -258,6 +258,16 @@ implements
ctx.sql(')');
break;
case CUBRID:
ctx.visit(sequence).sql('.');
if (method == SequenceMethod.NEXTVAL)
ctx.visit(DSL.keyword("next_value"));
else
ctx.visit(DSL.keyword("current_value"));
break;
case DERBY:
case FIREBIRD:
@ -289,19 +299,8 @@ implements
else {
throw new SQLDialectNotSupportedException("The sequence's current value functionality is not supported for the " + family + " dialect.");
}
break;
case CUBRID:
ctx.visit(sequence).sql('.');
if (method == SequenceMethod.NEXTVAL)
ctx.visit(DSL.keyword("next_value"));
else
ctx.visit(DSL.keyword("current_value"));
ctx.visit(sequence).sql('.').visit(method.keyword);
break;