Reputation: 23352
I am using pgAdmin version 1.14.3. PostgreSQL database version is 9.1.
I got all Db script for table creation but unable to export all data inside tables. Could not find any option to export data in db script form.
Upvotes: 168
Views: 336540
Reputation: 2569
Backup
..PLAIN
for FormatUSE INSERT COMMANDS
Use Column Inserts
if you want column names in your inserts.Backup
buttonEdit: In case you are using pgAdmin on a remote server: Once the UI announces the backup was successful, you might want to download the data. For this, follow these steps:
Upvotes: 235
Reputation: 4381
In the pgAdmin4, Right click on table select backup like this
After that into the backup dialog there is Dump options tab into that there is section queries you can select Use Insert Commands which include all insert queries as well in the backup.
Upvotes: 24
Reputation: 127446
Just right click on a table and select "backup". The popup will show various options, including "Format", select "plain" and you get plain SQL.
pgAdmin is just using pg_dump to create the dump, also when you want plain SQL.
It uses something like this:
pg_dump --user user --password --format=plain --table=tablename --inserts --attribute-inserts etc.
Upvotes: 168