Skip to content

Commit

Permalink
Fix incorrect comment
Browse files Browse the repository at this point in the history
  • Loading branch information
hashhar committed Aug 11, 2021
1 parent 33be493 commit 3eaf4bb
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -783,7 +783,7 @@ public OptionalLong delete(ConnectorSession session, JdbcTableHandle handle)
PreparedQuery preparedQuery = queryBuilder.prepareDelete(session, connection, handle.getRequiredNamedRelation(), handle.getConstraint());
try (PreparedStatement preparedStatement = queryBuilder.prepareStatement(session, connection, preparedQuery)) {
int affectedRowsCount = preparedStatement.executeUpdate();
// connection.getAutoCommit() is not enough for PostgreSQL to make DELETE effective and explicit commit is required
// In getPreparedStatement we set autocommit to false so here we need an explicit commit
connection.commit();
return OptionalLong.of(affectedRowsCount);
}
Expand Down

0 comments on commit 3eaf4bb

Please sign in to comment.