diff --git a/includes/database/pgsql/query.inc b/includes/database/pgsql/query.inc index e387e89..73c23b0 100644 --- a/includes/database/pgsql/query.inc +++ b/includes/database/pgsql/query.inc @@ -154,13 +154,13 @@ class UpdateQuery_pgsql extends UpdateQuery { $blobs = array(); $blob_count = 0; + // Unselect rows that don't have to be changed on update ('no-op rows'). + $this->unselectNoOpRows(); + // Because we filter $fields the same way here and in __toString(), the // placeholders will all match up properly. $stmt = $this->connection->prepareQuery((string) $this); - // Unselect rows that don't have to be changed on update ('no-op rows'). - $this->unselectNoOpRows(); - // Fetch the list of blobs and sequences used on that table. $table_information = $this->connection->schema()->queryTableInformation($this->table); @@ -206,7 +206,7 @@ class UpdateQuery_pgsql extends UpdateQuery { $options = $this->queryOptions; $options['already_prepared'] = TRUE; - $this->connection->query($stmt, $options); + $this->connection->query($stmt, array(), $options); return $stmt->rowCount(); }