On 2024-11-19 16:47:40 -0500, Catherine Frock wrote: > I am trying to restore a previously backed up database .sql file that was > created in PostgreSQL 9.6 using pgAdmin4 (I'm not sure which version I was > using). > > In response to Ron: Do I need to use PG16 instead of pgAdmin4? As Ron already pointed out, these are different things. PostgreSQL is a Database. PgAdmin ist a Client for that database. You can't use one instead of the other. You can only use them together (but of course you could use a different client instead of PgAdmin4). > I set the PostgreSQL Binary Path to: C:\Program > Files\PostgreSQL\17\bin. I have tried to restore my database using > this in the command prompt: "psql.exe db_2024_9 < > C:\postgis\db_2017-08-16.sql postgres" using an empty database in both > the PostgreSQL 9.6 and 17 servers, and this is the result: > > Password for user postgres: > SET [...] > ALTER TABLE > ERROR: role "basic_user" does not exist [...] > ALTER DEFAULT PRIVILEGES > ERROR: role "basic_user" does not exist That looks fine except that the user "basic_user" doesn't exist. You should create that before restoring the backup. Or could fix the errors after the fact but for that you need to understand what went wrong. hp -- _ | Peter J. Holzer | Story must make more sense than reality. |_|_) | | | | | hjp@xxxxxx | -- Charles Stross, "Creative writing __/ | http://www.hjp.at/ | challenge!"
Attachment:
signature.asc
Description: PGP signature