Explore information related to restore postgres database from dump mac
psql to restore a text dump How to do it
This article will guide you on steps to perform text dump restoration. Basically, psql restores a text dump in the same file format.
You can backup a single table, a #schema, or a complete database. Select the name of the backup source in the #pgAdmin tree control, right click to open the context menu, and select Backup… to open the #Backup dialog.
The name of the object selected will appear in the dialog title bar.
In #PostgreSQL, you can restore a database in two ways:
i. Using psql to restore plain #SQL script file generated by pg_dump and pg_dumpall tools.
ii. Using pg_restore to restore tar file and directory format created by the pg_dump tool.
To Restore Postgres Database:
1. Restore a postgres database. $ psql -U erp -d erp_devel -f mydb.sql.
2. Backup a local postgres database and restore to remote server using single command: $ pg_dump dbname | psql -h hostname dbname.
3. Restore all the postgres databases.
4. Restore a single postgres table.
