NAME

pg2rdb - extract a PostgreSQL table into an RDB table


SYNOPSIS

pg2rdb [options] table [column names]


DESCRIPTION

pg2rdb extracts data from the specified PostgreSQL table into an RDB table. Column types are determined from the PostgreSQL type. By default all columns are output; the user may optionally specify a list of columns on the command line.

If --verbose is specified, a continuously updated report of pg2rdb's activity is printed,


OPTIONS

Options are specified using a getopt style interface. Long names are available when preceded with double hyphens --, in which case only the minimal number of characters are required. Options which take values may be separated from those values with the = character or by whitespace.

--db=string
The name of the PostgreSQL database to which to connect.

--table=string
The name of the table from which to extract the data

output=file
The RDB file to which the data will be written. If it is the string stdout, it is written to the standard output stream.

--host=string
The PostgreSQL server. If not set, pg2rdb will use the contents of the PGHOST environmental variable.

--user=string
The database user name. It defaults to the login name of the user running pg2rdb.

--datestyle=string
Output all times, dates, timespans, etc in given format. Formats can be ISO, SQL, Postgres, European, NonEuropean, US, or default. See the PostgreSQL set manpage for further info on the various formats.

--np=integer
The number of records per output period character printed during verbose mode. Defaults to 10.

--npl=integer
The number of periods output per line during verbose mode. Defaults to 50.

--help
Print a brief help message and exit.

--usage
Print a detailed help message and exit.

--verbose
If specified, pg2rdb will be noisy.

--version boolean
If specified, pg2rdb will write version information to the standard output stream and then exit.


AUTHOR

Diab Jerius (djerius@cfa.harvard.edu)