postgresql/src/bin/pg_dump
Bruce Momjian 1e801a8f16 Hi,
Attached you'll find a (big) patch that fixes make dep and make
depend in all Makefiles where I found it to be appropriate.

It also removes the dependency in Makefile.global for NAMEDATALEN
and OIDNAMELEN by making backend/catalog/genbki.sh and bin/initdb/initdb.sh
a little smarter.

This no longer requires initdb.sh that is turned into initdb with
a sed script when installing Postgres, hence initdb.sh should be
renamed to initdb (after the patch has been applied :-) )

This patch is against the 6.3 sources, as it took a while to
complete.

Please review and apply,

Cheers,

Jeroen van Vianen
1998-04-06 00:32:26 +00:00
..
common.c pgindent run before 6.3 release, with Thomas' requested changes. 1998-02-26 04:46:47 +00:00
Makefile.in Hi, 1998-04-06 00:32:26 +00:00
pg_dump.c There's a patch attached to fix gcc 2.8.x warnings, except for the 1998-03-30 16:47:35 +00:00
pg_dump.h Change Postgres95 to PostgreSQL. Update CLUSTER manual page. 1998-03-14 21:58:09 +00:00
pg_dumpall Rename pg_user to pg_shadow. 1998-03-06 17:25:51 +00:00
README Change Postgres95 to PostgreSQL. Update CLUSTER manual page. 1998-03-14 21:58:09 +00:00

pg_dump is a utility for dumping out a postgres database into a script
file containing query commands.  The script files are in a ASCII
format and can be used to reconstruct the database, even on other
machines and other architectures.  pg_dump will produce the queries
necessary to re-generate all user-defined types, functions, tables,
indices, aggregates, and operators.  In addition, all the data is
copied out in ASCII format so that it can be readily copied in again.


To build:

	   % gmake clean install

This version of the program will read in your postgreSQL database and
output the schema and the data tuples in SQL.  The dumps are useful
for moving from one postgreSQL installation to another.  


How to use pg_dump:
-------------------

The command line options are fairly self explanatory.  Use -help to
see the command line options.   recommend using -v to get
more verbose descriptions of what pg_dump is doing.

After running pg_dump, one should examine the output script file for any 
warnings, especially in light of the limitations listed below.

A typical use of pg_dump:

	%  pg_dump -v -f oldDB.dump  oldDB
	%  createdb newDB
 	%  psql newDB < oldDB.dump


Caveats and limitations:
------------------------

pg_dump has a few limitations.  The limitations mostly stem from
difficulty in extracting certain meta-information from the system
catalogs.   

   rules and views:  
	pg_dump does not understand user-defined rules and views and
	will fail to dump them properly.  (This is due to the fact that
	rules are stored as plans in the catalogs and not textually)
	
   partial indices:
	pg_dump does not understand partial indices. (The reason is
	the same as above.  Partial index predicates are stored as plans)
	
   large objects:
	pg_dump does not handle large objects.  Large
	objects are ignored and must be dealt with manually.

   oid preservation:
 	pg_dump does not preserve oid's while dumping.  If you have
	stored oid's explicitly in tables in user-defined attributes,
	and are using them as keys, then the output scripts will not
	regenerate your database correctly. 

pg_dump requires postgres95 beta0.03 or later.

Bug-reporting
--------------

If you should find a problem with pg_dump, it is very important that
you provide a (small) sample database which illustrates the problem.
Please send bugs, questions, and feedback to the
	postgres95@postgres95.vnet.net