[jOOQ/jOOQ#9985] FieldMapsForInsert::toSQLReferenceKeys should use QueryPartList
This commit is contained in:
parent
58c0072866
commit
787878ed80
@ -501,33 +501,13 @@ final class FieldMapsForInsert extends AbstractQueryPart {
|
||||
return;
|
||||
}
|
||||
|
||||
boolean indent = (values.size() > 1);
|
||||
|
||||
ctx.sql(" (");
|
||||
|
||||
if (indent)
|
||||
ctx.formatIndentStart();
|
||||
|
||||
// [#989] Avoid qualifying fields in INSERT field declaration
|
||||
boolean qualify = ctx.qualify();
|
||||
ctx.qualify(false);
|
||||
|
||||
String separator = "";
|
||||
for (Field<?> field : values.keySet()) {
|
||||
ctx.sql(separator);
|
||||
|
||||
if (indent)
|
||||
ctx.formatNewLine();
|
||||
|
||||
ctx.visit(field);
|
||||
separator = ", ";
|
||||
}
|
||||
|
||||
ctx.qualify(qualify);
|
||||
|
||||
if (indent)
|
||||
ctx.formatIndentEnd()
|
||||
.formatNewLine();
|
||||
ctx.qualify(false)
|
||||
.visit(new QueryPartList<>(values.keySet()))
|
||||
.qualify(qualify);
|
||||
|
||||
ctx.sql(')');
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user