Skip to content
This repository has been archived by the owner on Sep 13, 2024. It is now read-only.

Commit

Permalink
DBZ-7956 Fix UPDATE/DELETE statement column name resolution
Browse files Browse the repository at this point in the history
Certain databases like Oracle and Db2 upper case identifiers by default while
others like PostgreSQL lowercase identifiers. The tests primarily use lower
case so this wasn't visible on PG tests; however, after adding the guard for
NullPointerException, several tests failed.  This addresses the bug for Oracle,
Db2, and PostgreSQL.
  • Loading branch information
Naros committed Jun 18, 2024
1 parent 3ae7240 commit 9dc7dcb
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -763,7 +763,7 @@ protected String getQualifiedTableName(TableId tableId) {

private String columnNameEqualsBinding(String fieldName, TableDescriptor table, SinkRecordDescriptor record) {
final FieldDescriptor field = record.getFields().get(fieldName);
final String columnName = columnNamingStrategy.resolveColumnName(field.getColumnName());
final String columnName = resolveColumnName(field);
final ColumnDescriptor column = table.getColumnByName(columnName);
return toIdentifier(columnName) + "=" + field.getQueryBinding(column, record.getAfterStruct());
}
Expand Down

0 comments on commit 9dc7dcb

Please sign in to comment.