Skip to content

Commit

Permalink
Correct the Database Connection (#120)
Browse files Browse the repository at this point in the history
Using the correct db connection for ALTER schema operations.
  • Loading branch information
apeschel authored Jul 20, 2023
1 parent 0660c2d commit cd8885d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/postgres/database.go
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ func (c *pg) CreateSchema(db, role, schema string, logger logr.Logger) error {
// Set the schema owner in a separate step, because AWS RDS breaks if
// you try to create a schema and set the owner in a single command.
// See: https://github.com/movetokube/postgres-operator/issues/91
_, err = c.db.Exec(fmt.Sprintf(ALTER_SCHEMA_OWNER, schema, role))
_, err = tmpDb.Exec(fmt.Sprintf(ALTER_SCHEMA_OWNER, schema, role))
if err != nil {
return err
}
Expand Down

0 comments on commit cd8885d

Please sign in to comment.