I was exporting a database using
pg_dump command when I realized that the owner of the database had to be changed. So I change it, and make extra sure that the
newuser is correct. Then try the command again:
pg_dump -h localhost -U postgres database_name -f mydb.dump
But this didn't work. The output file still identified the owner as the
olduser. Why could this be happening? How can I make sure this doesn't happen?