[#4151] FOR UPDATE .. OF doesn't allow qualified column names
This commit is contained in:
parent
fad302058c
commit
016928311d
@ -469,8 +469,10 @@ class SelectQueryImpl<R extends Record> extends AbstractResultQuery<R> implement
|
||||
.keyword("for update");
|
||||
|
||||
if (!forUpdateOf.isEmpty()) {
|
||||
context.sql(' ').keyword("of").sql(' ');
|
||||
Utils.fieldNames(context, forUpdateOf);
|
||||
context.sql(' ').keyword("of")
|
||||
.sql(' ').visit(forUpdateOf);
|
||||
|
||||
// Utils.fieldNames(context, forUpdateOf);
|
||||
}
|
||||
else if (!forUpdateOfTables.isEmpty()) {
|
||||
context.sql(' ').keyword("of").sql(' ');
|
||||
@ -486,7 +488,7 @@ class SelectQueryImpl<R extends Record> extends AbstractResultQuery<R> implement
|
||||
xxxx xxxxxxx
|
||||
xx [/pro] */
|
||||
case DERBY: {
|
||||
forUpdateOfTables.toSQLFieldNames(context);
|
||||
forUpdateOfTables.toSQLFields(context);
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
@ -76,13 +76,13 @@ class TableList extends QueryPartList<Table<?>> {
|
||||
* Get a list of names of the <code>NamedQueryParts</code> contained in this
|
||||
* list.
|
||||
*/
|
||||
final void toSQLFieldNames(Context<?> ctx) {
|
||||
final void toSQLFields(Context<?> ctx) {
|
||||
String separator = "";
|
||||
|
||||
for (Table<?> table : this) {
|
||||
for (Field<?> field : table.fieldsRow().fields()) {
|
||||
ctx.sql(separator);
|
||||
ctx.literal(field.getName());
|
||||
ctx.visit(field);
|
||||
|
||||
separator = ", ";
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user