Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 6568939

Browse files
committed
Mention that COPY cannot be used on a view (per recent suggestion).
Other small improvements.
1 parent 135dea6 commit 6568939

File tree

1 file changed

+14
-7
lines changed

1 file changed

+14
-7
lines changed

doc/src/sgml/ref/copy.sgml

Lines changed: 14 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<!--
2-
$Header: /cvsroot/pgsql/doc/src/sgml/ref/copy.sgml,v 1.21 2001/05/27 09:59:27 petere Exp $
2+
$Header: /cvsroot/pgsql/doc/src/sgml/ref/copy.sgml,v 1.22 2001/08/10 23:09:30 tgl Exp $
33
Postgres documentation
44
-->
55

@@ -65,7 +65,7 @@ COPY [ BINARY ] <replaceable class="parameter">table</replaceable> [ WITH OIDS ]
6565
<term>WITH OIDS</term>
6666
<listitem>
6767
<para>
68-
Specifies copying the internal unique object id (OID) for each row.
68+
Specifies copying the internal object id (OID) for each row.
6969
</para>
7070
</listitem>
7171
</varlistentry>
@@ -181,12 +181,12 @@ ERROR: <replaceable>reason</replaceable>
181181
</para>
182182

183183
<para>
184-
<command>COPY</command> instructs
184+
<command>COPY</command> with a filename instructs
185185
the <productname>Postgres</productname> backend
186-
to directly read from or write to a file. If a file name is specified,
187-
the file must be accessible to the backend and the name must be specified
186+
to directly read from or write to a file.
187+
The file must be accessible to the backend and the name must be specified
188188
from the viewpoint of the backend.
189-
If <filename>stdin</filename> or <filename>stdout</filename> is
189+
When <filename>stdin</filename> or <filename>stdout</filename> is
190190
specified, data flows through the client frontend to the backend.
191191

192192
<tip>
@@ -209,6 +209,11 @@ ERROR: <replaceable>reason</replaceable>
209209
<title>
210210
Notes
211211
</title>
212+
<para>
213+
<command>COPY</command> can only be used with plain tables, not with
214+
views.
215+
</para>
216+
212217
<para>
213218
The BINARY keyword will force all data to be
214219
stored/read as binary format rather than as text. It is
@@ -318,6 +323,8 @@ ERROR: <replaceable>reason</replaceable>
318323
</para>
319324
<para>
320325
The OID is emitted as the first column if WITH OIDS is specified.
326+
(An error is raised if WITH OIDS is specified for a table that does not
327+
have OIDs.)
321328
</para>
322329
<para>
323330
If <command>COPY TO</command> is sending its output to standard
@@ -525,7 +532,7 @@ If OIDs are included in the dump, the OID field immediately follows the
525532
field-count word. It is a normal field except that it's not included
526533
in the field-count. In particular it has a typlen --- this will allow
527534
handling of 4-byte vs 8-byte OIDs without too much pain, and will allow
528-
OIDs to be shown as NULL if we someday allow OIDs to be optional.
535+
OIDs to be shown as NULL if that ever proves desirable.
529536
</para>
530537
</refsect3>
531538

0 commit comments

Comments
 (0)