Hi Peter,
1) We are using "psql 7.4.2" version of Postgresql, need to create a new schema similar to the current schema with all the objects as in the current schema. Do we have any command to support this operation?
2) We need to shift all the data between 2 different databases in 2 different servers. What is the best way to go either backup or copy command?
3) Any equivalent command to export and import commands in Oracle/SQL.
Can you please give some knowledge on this
pg_dump -s -h olddbserver olddbname > schemafile.sql
psql -h newserver newdbname < svhemafile.sql
2: pg_dump is the best way to go. pg_dumpall can dump everything, including user accounts from one server. Then feed the output to psql or pg_restore.
3: pg_dump is export, psql or pg_restore are import