snuyanzin commented on code in PR #27594:
URL: https://github.com/apache/flink/pull/27594#discussion_r2888857139
##########
flink-table/flink-table-api-java/src/main/java/org/apache/flink/table/operations/materializedtable/MaterializedTableChangeHandler.java:
##########
@@ -418,58 +424,55 @@ private void
checkForChangedPositionByQuery(List<TableChange> tableChanges, Sche
oldColumns.get(persistedColumnOffset).getName(),
newColumn);
}
} else {
- afterToColumnName.put(((TableChange.After) position).column(),
newColumn);
+ afterToColumnName.put(((After) position).column(), newColumn);
}
}
- for (int i = 1; i < oldColumns.size(); i++) {
+ for (int i = 0; i < oldColumns.size() - 1; i++) {
Review Comment:
better to start with 0 in case there is last column swapped with something
else
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]