Skip to content

Commit

Permalink
PG Resync Query: Fix syntax (#2156)
Browse files Browse the repository at this point in the history
Missing a space between words in the rename query
  • Loading branch information
Amogh-Bharadwaj authored Oct 17, 2024
1 parent 43ccfe3 commit 053f1e8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion flow/connectors/postgres/postgres.go
Original file line number Diff line number Diff line change
Expand Up @@ -1389,7 +1389,7 @@ func (c *PostgresConnector) RenameTables(
c.logger.Info(fmt.Sprintf("handling soft-deletes for table '%s'...", dst))
_, err = c.execWithLoggingTx(ctx,
fmt.Sprintf(
"INSERT INTO %s(%s) SELECT %s,true AS %s FROM %s original_table"+
"INSERT INTO %s(%s) SELECT %s,true AS %s FROM %s original_table "+
"WHERE NOT EXISTS (SELECT 1 FROM %s resync_table WHERE %s)",
src, fmt.Sprintf("%s,%s", allCols, QuoteIdentifier(req.SoftDeleteColName)), allCols, req.SoftDeleteColName,
dst, src, pkeyColCompareStr), renameTablesTx)
Expand Down

0 comments on commit 053f1e8

Please sign in to comment.