Restoring from a backup of file.

Questions and answers regarding general SQL and backend databases

Restoring from a backup of file.

Postby ashutos » Tue Nov 08, 2011 11:32 am

Hi All ,

I am having a postgres backupfile with name x.sqlc. I want to restore it . It is using an user with name "Postgres" . I have created the user postgres . I have added the user in the database. But still during the restore i am getting the following exception.Please help


C:\Program Files\pgAdmin III\1.12\pg_restore.exe --host localhost --port 5432 --username "DBA" --dbname rfs --verbose "C:\Users\ashutosl\Desktop\RFS Info\rfs11.07.2011_23.00.sqlc"
pg_restore: connecting to database for restore
pg_restore: creating SCHEMA public
pg_restore: creating COMMENT SCHEMA public
pg_restore: creating PROCEDURAL LANGUAGE plpgsql
pg_restore: [archiver (db)] Error while PROCESSING TOC:
pg_restore: [archiver (db)] Error from TOC entry 404; 2612 11574 PROCEDURAL LANGUAGE plpgsql postgres
pg_restore: [archiver (db)] could not execute query: ERROR: syntax error at or near "PROCEDURAL"
LINE 2: CREATE OR REPLACE PROCEDURAL LANGUAGE plpgsql;


Thanks in advance . Waitng for your feedback.
Thanks
Ashutos
ashutos
 
Posts: 72
Joined: Fri Apr 16, 2010 1:06 pm

Re: Restoring from a backup of file.

Postby rgansevles » Tue Nov 08, 2011 12:40 pm

Ashutos,

With which version of pg_dump was the backup created and with which versions of pg_restore or the pg db do you want to restore?

Rob
Rob Gansevles
Servoy
User avatar
rgansevles
 
Posts: 1927
Joined: Wed Nov 15, 2006 6:17 pm
Location: Amersfoort, NL

Re: Restoring from a backup of file.

Postby ashutos » Tue Nov 08, 2011 12:52 pm

Hi Rob,

Thanks for your reply . May be the backup is created with pg 5.2.8 . And I am doing the restore with pg 5.2.9. I am using PG Admin 1.12.1.Can the back up file be.sqlc file.
But I guess we require .backup file ?.



Please do help.
Thanks,
Ashutos.
Thanks
Ashutos
ashutos
 
Posts: 72
Joined: Fri Apr 16, 2010 1:06 pm

Re: Restoring from a backup of file.

Postby rgansevles » Tue Nov 08, 2011 2:04 pm

Ashutos,

I guess you mean Servoy 5.2.*, not postgres?

The 5.2.* postgres are bundled with the same version, but it seems you are using the pg_restore from pgadmin3, not the one bundled with Servoy.
Try the one in /path/to/servoy/application_server/postgres_db/bin/pg_restore.exe

Rob
Rob Gansevles
Servoy
User avatar
rgansevles
 
Posts: 1927
Joined: Wed Nov 15, 2006 6:17 pm
Location: Amersfoort, NL


Return to SQL Databases

Who is online

Users browsing this forum: No registered users and 3 guests