Re: Dump to text file

From: Mauricio Alarcon <malarcon(at)webdepot(dot)com(dot)co>
To: Mike Hammonds <mhammonds(at)knowledgeinenergy(dot)com>
Cc: pgadmin-support(at)greatbridge(dot)org, pgsql-novice(at)postgresql(dot)org
Subject: Re: Dump to text file
Date: 2001-01-03 15:18:47
Message-ID: 3A5342D7.3030801@webdepot.com.co
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

with pg_dump, I use in this form

pg_dump mydb > mydb.pg_dump

pg_dump dumps a database as a text file.

Usage:
pg_dump [options] dbname

Options:
-a, --data-only dump out only the data, not the schema
-c, --clean clean (drop) schema prior to create
-d, --inserts dump data as INSERT, rather than COPY, commands
-D, --attribute-inserts dump data as INSERT commands with attribute names
-h, --host <hostname> server host name
-i, --ignore-version proceed when database version != pg_dump version
-n, --no-quotes suppress most quotes around identifiers
-N, --quotes enable most quotes around identifiers
-o, --oids dump object ids (oids)
-p, --port <port> server port number
-s, --schema-only dump out only the schema, no data
-t, --table <table> dump for this table only
-u, --password use password authentication
-v, --verbose verbose
-x, --no-acl do not dump ACL's (grant/revoke)

If no database name is not supplied, then the PGDATABASE environment
variable value is used.

Mike Hammonds wrote:

> ** Reply Requested When Convenient **
>
> How do I dump a database to a text file from the command line?
>
> Mike Hammonds, CNE5, MCP-NT
> Fellon-McCord & Associates, Inc.
> Office: 502.214-6324
> Fax: 502.426.8800
> mhammonds(at)knowledgeinenergy(dot)com
> Show Me the Code!!
>
>
> ------------------------------------------------------------------------
>
> BEGIN:VCARD
> VERSION:2.1
> X-GWTYPE:USER
> FN:Mike Hammonds
> TEL;WORK:(502)214-6324
> ORG:;IS Department
> TEL;PREF;FAX:(502)426-8800
> EMAIL;WORK;PREF;NGW:Mike(dot)Hammonds(at)knowledgeinenergy(dot)com
> N:Hammonds;Mike
> TITLE:IS MAnager
> X-GWUSERID:mhammonds
> END:VCARD
>
> attachment.txt
>
> Content-Type:
>
> text/plain
> Content-Encoding:
>
> quoted-printable
>
>
> ------------------------------------------------------------------------
> Mike Hammonds.vcf
>
> Content-Type:
>
> text/plain
>
>

--
Mauricio Alarcon Rincon
Webmaster - Webdepot
CF-18 Hornet
\ /
\ _ /
----/_\----
x--------------( . )--------------x
x|x | |_|\_/|_| | x|x
x x x x

In response to

Browse pgsql-novice by date

  From Date Subject
Next Message Alan Nilsson 2001-01-03 18:11:36 Changing users passwords
Previous Message Mike Hammonds 2001-01-03 15:13:06 Dump to text file