Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
Postgres FD Implementation
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Abuhujair Javed
Postgres FD Implementation
Commits
1d27de4c
Commit
1d27de4c
authored
Nov 04, 2003
by
Peter Eisentraut
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Random copy-editing.
parent
c119c554
Changes
21
Show whitespace changes
Inline
Side-by-side
Showing
21 changed files
with
571 additions
and
588 deletions
+571
-588
doc/src/sgml/array.sgml
doc/src/sgml/array.sgml
+48
-15
doc/src/sgml/backup.sgml
doc/src/sgml/backup.sgml
+30
-18
doc/src/sgml/charset.sgml
doc/src/sgml/charset.sgml
+5
-8
doc/src/sgml/client-auth.sgml
doc/src/sgml/client-auth.sgml
+22
-21
doc/src/sgml/datatype.sgml
doc/src/sgml/datatype.sgml
+8
-8
doc/src/sgml/ddl.sgml
doc/src/sgml/ddl.sgml
+7
-7
doc/src/sgml/features.sgml
doc/src/sgml/features.sgml
+2
-2
doc/src/sgml/func.sgml
doc/src/sgml/func.sgml
+22
-21
doc/src/sgml/install-win32.sgml
doc/src/sgml/install-win32.sgml
+13
-13
doc/src/sgml/installation.sgml
doc/src/sgml/installation.sgml
+232
-253
doc/src/sgml/maintenance.sgml
doc/src/sgml/maintenance.sgml
+5
-5
doc/src/sgml/monitoring.sgml
doc/src/sgml/monitoring.sgml
+8
-7
doc/src/sgml/mvcc.sgml
doc/src/sgml/mvcc.sgml
+11
-16
doc/src/sgml/postgres.sgml
doc/src/sgml/postgres.sgml
+2
-2
doc/src/sgml/queries.sgml
doc/src/sgml/queries.sgml
+7
-7
doc/src/sgml/ref/pg_dump.sgml
doc/src/sgml/ref/pg_dump.sgml
+2
-2
doc/src/sgml/ref/pg_dumpall.sgml
doc/src/sgml/ref/pg_dumpall.sgml
+2
-2
doc/src/sgml/regress.sgml
doc/src/sgml/regress.sgml
+3
-9
doc/src/sgml/runtime.sgml
doc/src/sgml/runtime.sgml
+103
-96
doc/src/sgml/syntax.sgml
doc/src/sgml/syntax.sgml
+30
-68
doc/src/sgml/typeconv.sgml
doc/src/sgml/typeconv.sgml
+9
-8
No files found.
doc/src/sgml/array.sgml
View file @
1d27de4c
<!-- $Header: /cvsroot/pgsql/doc/src/sgml/array.sgml,v 1.3
2 2003/11/01 01:56:2
8 petere Exp $ -->
<!-- $Header: /cvsroot/pgsql/doc/src/sgml/array.sgml,v 1.3
3 2003/11/04 09:55:3
8 petere Exp $ -->
<sect1 id="arrays">
<sect1 id="arrays">
<title>Arrays</title>
<title>Arrays</title>
...
@@ -76,13 +76,45 @@ CREATE TABLE tictactoe (
...
@@ -76,13 +76,45 @@ CREATE TABLE tictactoe (
<sect2>
<sect2>
<title>Array Value Input</title>
<title>Array Value Input</title>
<indexterm>
<primary>array</primary>
<secondary>constant</secondary>
</indexterm>
<para>
<para>
Now we can show some <command>INSERT</command> statements. To write an array
To write an array value as a literal constant, enclose the element
value as a literal constant, we enclose the element values within curly
values within curly braces and separate them by commas. (If you
braces and separate them by commas. (If you know C, this is not unlike the
know C, this is not unlike the C syntax for initializing
C syntax for initializing structures.) We may put double quotes around any
structures.) You may put double quotes around any element value,
element value, and must do so if it contains commas or curly braces.
and must do so if it contains commas or curly braces. (More
(More details appear below.)
details appear below.) Thus, the general format of an array
constant is the following:
<synopsis>
'{ <replaceable>val1</replaceable> <replaceable>delim</replaceable> <replaceable>val2</replaceable> <replaceable>delim</replaceable> ... }'
</synopsis>
where <replaceable>delim</replaceable> is the delimiter character
for the type, as recorded in its <literal>pg_type</literal> entry.
(For all built-in types, this is the comma character
<quote><literal>,</literal></>.) Each
<replaceable>val</replaceable> is either a constant of the array
element type, or a subarray. An example of an array constant is
<programlisting>
'{{1,2,3},{4,5,6},{7,8,9}}'
</programlisting>
This constant is a two-dimensional, 3-by-3 array consisting of
three subarrays of integers.
</para>
<para>
(These kinds of array constants are actually only a special case of
the generic type constants discussed in <xref
linkend="sql-syntax-constants-generic">. The constant is initially
treated as a string and passed to the array input conversion
routine. An explicit type specification might be necessary.)
</para>
<para>
Now we can show some <command>INSERT</command> statements.
<programlisting>
<programlisting>
INSERT INTO sal_emp
INSERT INTO sal_emp
...
@@ -99,10 +131,11 @@ INSERT INTO sal_emp
...
@@ -99,10 +131,11 @@ INSERT INTO sal_emp
<para>
<para>
A limitation of the present array implementation is that individual
A limitation of the present array implementation is that individual
elements of an array cannot be SQL null values. The entire array can be set
elements of an array cannot be SQL null values. The entire array
to null, but you can't have an array with some elements null and some
can be set to null, but you can't have an array with some elements
not.
null and some
not.
</para>
</para>
<para>
<para>
This can lead to surprising results. For example, the result of the
This can lead to surprising results. For example, the result of the
previous two inserts looks like this:
previous two inserts looks like this:
...
...
doc/src/sgml/backup.sgml
View file @
1d27de4c
<!--
<!--
$Header: /cvsroot/pgsql/doc/src/sgml/backup.sgml,v 2.3
0 2003/08/31 17:32:1
8 petere Exp $
$Header: /cvsroot/pgsql/doc/src/sgml/backup.sgml,v 2.3
1 2003/11/04 09:55:3
8 petere Exp $
-->
-->
<chapter id="backup">
<chapter id="backup">
<title>Backup and Restore</title>
<title>Backup and Restore</title>
...
@@ -155,8 +155,9 @@ pg_dump -h <replaceable>host1</> <replaceable>dbname</> | psql -h <replaceable>h
...
@@ -155,8 +155,9 @@ pg_dump -h <replaceable>host1</> <replaceable>dbname</> | psql -h <replaceable>h
<tip>
<tip>
<para>
<para>
Restore performance can be improved by increasing <literal>SORT_MEM</>
Restore performance can be improved by increasing the
(see <xref linkend="runtime-config-resource-memory">).
configuration parameter <varname>sort_mem</varname> (see <xref
linkend="runtime-config-resource-memory">).
</para>
</para>
</tip>
</tip>
</sect2>
</sect2>
...
@@ -333,12 +334,9 @@ tar -cf backup.tar /usr/local/pgsql/data
...
@@ -333,12 +334,9 @@ tar -cf backup.tar /usr/local/pgsql/data
going on. For this reason it is also not advisable to trust file
going on. For this reason it is also not advisable to trust file
systems that claim to support <quote>consistent
systems that claim to support <quote>consistent
snapshots</quote>. Information about stopping the server can be
snapshots</quote>. Information about stopping the server can be
found in <xref linkend="postmaster-shutdown">.
found in <xref linkend="postmaster-shutdown">. Needless to say
</para>
that you also need to shut down the server before restoring the
data.
<para>
Needless to say that you also need to shut down the server
before restoring the data.
</para>
</para>
</listitem>
</listitem>
...
@@ -362,7 +360,18 @@ tar -cf backup.tar /usr/local/pgsql/data
...
@@ -362,7 +360,18 @@ tar -cf backup.tar /usr/local/pgsql/data
</para>
</para>
<para>
<para>
Also note that the file system backup will not necessarily be
An alternative file-system backup approach is to make a
<quote>consistent snapshot</quote> of the data directory, if the
file system supports that functionality. Such a snapshot will save
the database files in a state where the database server was not
properly shut down; therefore, when you start the database server
on this backed up directory, it will think the server had crashed
and replay the WAL log. This is not a problem, just be aware of
it.
</para>
<para>
Note that the file system backup will not necessarily be
smaller than an SQL dump. On the contrary, it will most likely be
smaller than an SQL dump. On the contrary, it will most likely be
larger. (<application>pg_dump</application> does not need to dump
larger. (<application>pg_dump</application> does not need to dump
the contents of indexes for example, just the commands to recreate
the contents of indexes for example, just the commands to recreate
...
@@ -372,7 +381,7 @@ tar -cf backup.tar /usr/local/pgsql/data
...
@@ -372,7 +381,7 @@ tar -cf backup.tar /usr/local/pgsql/data
</sect1>
</sect1>
<sect1 id="migration">
<sect1 id="migration">
<title>Migration
between r
eleases</title>
<title>Migration
Between R
eleases</title>
<indexterm zone="migration">
<indexterm zone="migration">
<primary>upgrading</primary>
<primary>upgrading</primary>
...
@@ -385,17 +394,20 @@ tar -cf backup.tar /usr/local/pgsql/data
...
@@ -385,17 +394,20 @@ tar -cf backup.tar /usr/local/pgsql/data
<para>
<para>
As a general rule, the internal data storage format is subject to
As a general rule, the internal data storage format is subject to
change between releases of <productname>PostgreSQL</>. This does not
change between major releases of <productname>PostgreSQL</> (where
apply to different <quote>patch levels</quote>, these always have
the number after the first dot changes). This does not apply to
compatible storage formats. For example, releases 7.0.1, 7.1.2, and
different minor releases under the same major release (where the
7.2 are not compatible, whereas 7.1.1 and 7.1.2 are. When you
number of the second dot changes); these always have compatible
update between compatible versions, then you can simply reuse the
storage formats. For example, releases 7.0.1, 7.1.2, and 7.2 are
data area in disk by the new executables. Otherwise you need to
not compatible, whereas 7.1.1 and 7.1.2 are. When you update
between compatible versions, then you can simply reuse the data
area in disk by the new executables. Otherwise you need to
<quote>back up</> your data and <quote>restore</> it on the new
<quote>back up</> your data and <quote>restore</> it on the new
server, using <application>pg_dump</>. (There are checks in place
server, using <application>pg_dump</>. (There are checks in place
that prevent you from doing the wrong thing, so no harm can be done
that prevent you from doing the wrong thing, so no harm can be done
by confusing these things.) The precise installation procedure is
by confusing these things.) The precise installation procedure is
not subject of this section; these details are in <xref linkend="installation">.
not subject of this section; these details are in <xref
linkend="installation">.
</para>
</para>
<para>
<para>
...
...
doc/src/sgml/charset.sgml
View file @
1d27de4c
<!-- $Header: /cvsroot/pgsql/doc/src/sgml/charset.sgml,v 2.
39 2003/09/11 18:30:38 momjian
Exp $ -->
<!-- $Header: /cvsroot/pgsql/doc/src/sgml/charset.sgml,v 2.
40 2003/11/04 09:55:38 petere
Exp $ -->
<chapter id="charset">
<chapter id="charset">
<title>Localization</>
<title>Localization</>
...
@@ -248,12 +248,9 @@ initdb --locale=sv_SE
...
@@ -248,12 +248,9 @@ initdb --locale=sv_SE
<para>
<para>
Client applications that handle server-side errors by parsing the
Client applications that handle server-side errors by parsing the
text of the error message will obviously have problems when the
text of the error message will obviously have problems when the
server's messages are in a different language. If you create such
server's messages are in a different language. Authors of such
an application you need to devise a plan to cope with this
applications are advised to make use of the error code scheme
situation. The embedded SQL interface (<application>ECPG</>) is
instead.
also affected by this problem. It is currently recommended that
servers interfacing with <application>ECPG</> applications be
configured to send messages in English.
</para>
</para>
<para>
<para>
...
@@ -430,7 +427,7 @@ initdb --locale=sv_SE
...
@@ -430,7 +427,7 @@ initdb --locale=sv_SE
mistakenly meant ISO 8859-5. From 7.2 on, <literal>LATIN5</>
mistakenly meant ISO 8859-5. From 7.2 on, <literal>LATIN5</>
means ISO 8859-9. If you have a <literal>LATIN5</> database
means ISO 8859-9. If you have a <literal>LATIN5</> database
created on 7.1 or earlier and want to migrate to 7.2 or later,
created on 7.1 or earlier and want to migrate to 7.2 or later,
you should be
very
careful about this change.
you should be careful about this change.
</para>
</para>
</important>
</important>
...
...
doc/src/sgml/client-auth.sgml
View file @
1d27de4c
<!--
<!--
$Header: /cvsroot/pgsql/doc/src/sgml/client-auth.sgml,v 1.
59 2003/09/13 16:43:38 momjian
Exp $
$Header: /cvsroot/pgsql/doc/src/sgml/client-auth.sgml,v 1.
60 2003/11/04 09:55:38 petere
Exp $
-->
-->
<chapter id="client-authentication">
<chapter id="client-authentication">
...
@@ -89,9 +89,9 @@ local <replaceable>database</replaceable> <replaceable>user</replaceable> <r
...
@@ -89,9 +89,9 @@ local <replaceable>database</replaceable> <replaceable>user</replaceable> <r
host <replaceable>database</replaceable> <replaceable>user</replaceable> <replaceable>IP-address</replaceable> <replaceable>IP-mask</replaceable> <replaceable>authentication-method</replaceable> <optional><replaceable>authentication-option</replaceable></optional>
host <replaceable>database</replaceable> <replaceable>user</replaceable> <replaceable>IP-address</replaceable> <replaceable>IP-mask</replaceable> <replaceable>authentication-method</replaceable> <optional><replaceable>authentication-option</replaceable></optional>
hostssl <replaceable>database</replaceable> <replaceable>user</replaceable> <replaceable>IP-address</replaceable> <replaceable>IP-mask</replaceable> <replaceable>authentication-method</replaceable> <optional><replaceable>authentication-option</replaceable></optional>
hostssl <replaceable>database</replaceable> <replaceable>user</replaceable> <replaceable>IP-address</replaceable> <replaceable>IP-mask</replaceable> <replaceable>authentication-method</replaceable> <optional><replaceable>authentication-option</replaceable></optional>
hostnossl <replaceable>database</replaceable> <replaceable>user</replaceable> <replaceable>IP-address</replaceable> <replaceable>IP-mask</replaceable> <replaceable>authentication-method</replaceable> <optional><replaceable>authentication-option</replaceable></optional>
hostnossl <replaceable>database</replaceable> <replaceable>user</replaceable> <replaceable>IP-address</replaceable> <replaceable>IP-mask</replaceable> <replaceable>authentication-method</replaceable> <optional><replaceable>authentication-option</replaceable></optional>
host
<replaceable>database</replaceable> <replaceable>user</replaceable> <replaceable>IP-address</replaceable>/<replaceable>CIDR-mask
</replaceable> <replaceable>authentication-method</replaceable> <optional><replaceable>authentication-option</replaceable></optional>
host
<replaceable>database</replaceable> <replaceable>user</replaceable> <replaceable>IP-address</replaceable>/<replaceable>IP-masklen
</replaceable> <replaceable>authentication-method</replaceable> <optional><replaceable>authentication-option</replaceable></optional>
hostssl
<replaceable>database</replaceable> <replaceable>user</replaceable> <replaceable>IP-address</replaceable>/<replaceable>CIDR-mask
</replaceable> <replaceable>authentication-method</replaceable> <optional><replaceable>authentication-option</replaceable></optional>
hostssl
<replaceable>database</replaceable> <replaceable>user</replaceable> <replaceable>IP-address</replaceable>/<replaceable>IP-masklen
</replaceable> <replaceable>authentication-method</replaceable> <optional><replaceable>authentication-option</replaceable></optional>
hostnossl <replaceable>database</replaceable> <replaceable>user</replaceable> <replaceable>IP-address</replaceable>/<replaceable>
CIDR-mask
</replaceable> <replaceable>authentication-method</replaceable> <optional><replaceable>authentication-option</replaceable></optional>
hostnossl <replaceable>database</replaceable> <replaceable>user</replaceable> <replaceable>IP-address</replaceable>/<replaceable>
IP-masklen
</replaceable> <replaceable>authentication-method</replaceable> <optional><replaceable>authentication-option</replaceable></optional>
</synopsis>
</synopsis>
The meaning of the fields is as follows:
The meaning of the fields is as follows:
...
@@ -220,25 +220,26 @@ hostnossl <replaceable>database</replaceable> <replaceable>user</replaceable>
...
@@ -220,25 +220,26 @@ hostnossl <replaceable>database</replaceable> <replaceable>user</replaceable>
</varlistentry>
</varlistentry>
<varlistentry>
<varlistentry>
<term><replaceable>
CIDR-mask
</replaceable></term>
<term><replaceable>
IP-masklen
</replaceable></term>
<listitem>
<listitem>
<para>
<para>
This field may be used as an alternative to the
This field may be used as an alternative to the
<replaceable>IP-mask</replaceable> notation. It is an
<replaceable>IP-mask</replaceable> notation. It is an integer
integer specifying the number of high-order bits
specifying the number of high-order bits to set in the mask.
to set in the mask. The number must
The number must be between 0 and 32 (in the case of an IPv4
be between 0 and 32 (in the case of an IPv4 address) or 128
address) or 128 (in the case of an IPv6 address) inclusive. 0
(in the case of an IPv6 address) inclusive. 0 will match any
will match any address, while 32 (or 128, respectively) will
address, while 32/128 will match only the exact host specified.
match only the exact host specified. The same matching logic
The same matching logic is used as for a dotted notation
is used as for a dotted notation
<replaceable>IP-Mask</replaceable>.
<replaceable>IP-mask</replaceable>.
</para>
</para>
<para>
<para>
There must be no white space between the <replaceable>IP-address</replaceable>
There must be no white space between the
and the <literal>/</literal> or the <literal>/</literal> and the
<replaceable>IP-address</replaceable> and the
<replaceable>CIDR-mask</replaceable>, or the file will not be parsed
<literal>/</literal> or the <literal>/</literal> and the
correctly.
<replaceable>IP-masklen</replaceable>, or the file will not be
parsed correctly.
</para>
</para>
<para>
<para>
...
...
doc/src/sgml/datatype.sgml
View file @
1d27de4c
<!--
<!--
$Header: /cvsroot/pgsql/doc/src/sgml/datatype.sgml,v 1.12
8 2003/11/01 01:56:29
petere Exp $
$Header: /cvsroot/pgsql/doc/src/sgml/datatype.sgml,v 1.12
9 2003/11/04 09:55:38
petere Exp $
-->
-->
<chapter id="datatype">
<chapter id="datatype">
...
@@ -917,10 +917,10 @@ CREATE TABLE <replaceable class="parameter">tablename</replaceable> (
...
@@ -917,10 +917,10 @@ CREATE TABLE <replaceable class="parameter">tablename</replaceable> (
<para>
<para>
In addition, <productname>PostgreSQL</productname> provides the
In addition, <productname>PostgreSQL</productname> provides the
<type>text</type> type, which stores strings of any
<type>text</type> type, which stores strings of any
length.
length.
Although the type <type>text</type> is not in the
Although the type <type>text</type> is not in the
<acronym>SQL</acronym> standard, several other SQL database
products
<acronym>SQL</acronym> standard, several other SQL database
have it as well.
management systems
have it as well.
</para>
</para>
<para>
<para>
...
@@ -1464,7 +1464,7 @@ SELECT b, char_length(b) FROM test2;
...
@@ -1464,7 +1464,7 @@ SELECT b, char_length(b) FROM test2;
</row>
</row>
<row>
<row>
<entry>1999-01-08</entry>
<entry>1999-01-08</entry>
<entry>ISO
-
8601, January 8 in any mode
<entry>ISO
8601, January 8 in any mode
(recommended format)</entry>
(recommended format)</entry>
</row>
</row>
<row>
<row>
...
@@ -1486,11 +1486,11 @@ SELECT b, char_length(b) FROM test2;
...
@@ -1486,11 +1486,11 @@ SELECT b, char_length(b) FROM test2;
</row>
</row>
<row>
<row>
<entry>19990108</entry>
<entry>19990108</entry>
<entry>ISO
-
8601; January 8, 1999 in any mode</entry>
<entry>ISO
8601; January 8, 1999 in any mode</entry>
</row>
</row>
<row>
<row>
<entry>990108</entry>
<entry>990108</entry>
<entry>ISO
-
8601; January 8, 1999 in any mode</entry>
<entry>ISO
8601; January 8, 1999 in any mode</entry>
</row>
</row>
<row>
<row>
<entry>1999.008</entry>
<entry>1999.008</entry>
...
...
doc/src/sgml/ddl.sgml
View file @
1d27de4c
<!-- $Header: /cvsroot/pgsql/doc/src/sgml/ddl.sgml,v 1.2
1 2003/11/01 01:56:29
petere Exp $ -->
<!-- $Header: /cvsroot/pgsql/doc/src/sgml/ddl.sgml,v 1.2
2 2003/11/04 09:55:38
petere Exp $ -->
<chapter id="ddl">
<chapter id="ddl">
<title>Data Definition</title>
<title>Data Definition</title>
...
@@ -318,12 +318,12 @@ DROP TABLE products;
...
@@ -318,12 +318,12 @@ DROP TABLE products;
</para>
</para>
<para>
<para>
Transaction identifiers are also 32-bit quantities. In a
long-lived
Transaction identifiers are also 32-bit quantities. In a
database it is possible for transaction IDs to wrap around. This
long-lived database it is possible for transaction IDs to wrap
is not a fatal problem given appropriate maintenance procedures;
around. This is not a fatal problem given appropriate maintenance
see <xref linkend="maintenance"> for details. However, i
t is
procedures; see <xref linkend="maintenance"> for details. I
t is
unwise
to depend on uniqueness of transaction IDs over the long term
unwise
, however, to depend on the uniqueness of transaction IDs
(more than one billion transactions).
over the long term
(more than one billion transactions).
</para>
</para>
<para>
<para>
...
...
doc/src/sgml/features.sgml
View file @
1d27de4c
<!--
<!--
$Header: /cvsroot/pgsql/doc/src/sgml/features.sgml,v 2.2
0 2003/09/20 20:12:04 tgl
Exp $
$Header: /cvsroot/pgsql/doc/src/sgml/features.sgml,v 2.2
1 2003/11/04 09:55:38 petere
Exp $
-->
-->
<appendix id="features">
<appendix id="features">
...
@@ -30,7 +30,7 @@ $Header: /cvsroot/pgsql/doc/src/sgml/features.sgml,v 2.20 2003/09/20 20:12:04 tg
...
@@ -30,7 +30,7 @@ $Header: /cvsroot/pgsql/doc/src/sgml/features.sgml,v 2.20 2003/09/20 20:12:04 tg
<para>
<para>
<acronym>SQL92</acronym> defined three feature sets for conformance:
<acronym>SQL92</acronym> defined three feature sets for conformance:
Entry, Intermediate, and Full. Most database
product
s claiming
Entry, Intermediate, and Full. Most database
management system
s claiming
<acronym>SQL</acronym> standard conformance were conforming at only
<acronym>SQL</acronym> standard conformance were conforming at only
the Entry level, since the entire set of features in the
the Entry level, since the entire set of features in the
Intermediate and Full levels was either too voluminous or in
Intermediate and Full levels was either too voluminous or in
...
...
doc/src/sgml/func.sgml
View file @
1d27de4c
<!--
<!--
$Header: /cvsroot/pgsql/doc/src/sgml/func.sgml,v 1.17
7 2003/11/01 01:56:29
petere Exp $
$Header: /cvsroot/pgsql/doc/src/sgml/func.sgml,v 1.17
8 2003/11/04 09:55:38
petere Exp $
PostgreSQL documentation
PostgreSQL documentation
-->
-->
...
@@ -29,10 +29,10 @@ PostgreSQL documentation
...
@@ -29,10 +29,10 @@ PostgreSQL documentation
the functions and operators described in this chapter, with the
the functions and operators described in this chapter, with the
exception of the most trivial arithmetic and comparison operators
exception of the most trivial arithmetic and comparison operators
and some explicitly marked functions, are not specified by the
and some explicitly marked functions, are not specified by the
<acronym>SQL</acronym>
<acronym>SQL</acronym>
standard. Some of the extended functionality
standard. Some of the extended functionality is present in other
is present in other <acronym>SQL</acronym> database management
<acronym>SQL</acronym> implementations, and in many cases this
systems, and in many cases this functionality is compatible and
functionality is compatible and consistent between various product
s.
consistent between the various implementation
s.
</para>
</para>
...
@@ -7176,7 +7176,7 @@ SELECT pg_type_is_visible('myschema.widget'::regtype);
...
@@ -7176,7 +7176,7 @@ SELECT pg_type_is_visible('myschema.widget'::regtype);
</sect1>
</sect1>
<sect1 id="functions-array">
<sect1 id="functions-array">
<title>Array Functions</title>
<title>Array Functions
and Operators
</title>
<para>
<para>
<xref linkend="array-operators-table"> shows the operators
<xref linkend="array-operators-table"> shows the operators
...
@@ -7578,19 +7578,20 @@ SELECT pg_type_is_visible('myschema.widget'::regtype);
...
@@ -7578,19 +7578,20 @@ SELECT pg_type_is_visible('myschema.widget'::regtype);
<note>
<note>
<para>
<para>
Users accustomed to working with other RDBMS products may be
Users accustomed to working with other SQL database management
surprised by the performance characteristics of certain aggregate
systems may be surprised by the performance characteristics of
functions in <productname>PostgreSQL</productname> when the
certain aggregate functions in
aggregate is applied to the entire table (in other words, no
<productname>PostgreSQL</productname> when the aggregate is
<literal>WHERE</literal> clause is specified). In particular,
applied to the entire table (in other words, no
a query like
<literal>WHERE</literal> clause is specified). In particular, a
query like
<programlisting>
<programlisting>
SELECT min(col) FROM sometable;
SELECT min(col) FROM sometable;
</programlisting>
</programlisting>
will be executed by <productname>PostgreSQL</productname> using a
will be executed by <productname>PostgreSQL</productname> using a
sequential scan of the entire table. Other database systems may
sequential scan of the entire table. Other database systems may
optimize queries of this form to use an index on the column, if one
optimize queries of this form to use an index on the column, if
is available. Similarly, the aggregate functions
one
is available. Similarly, the aggregate functions
<function>max()</function> and <function>count()</function> always
<function>max()</function> and <function>count()</function> always
require a sequential scan if applied to the entire table in
require a sequential scan if applied to the entire table in
<productname>PostgreSQL</productname>.
<productname>PostgreSQL</productname>.
...
@@ -7602,8 +7603,8 @@ SELECT min(col) FROM sometable;
...
@@ -7602,8 +7603,8 @@ SELECT min(col) FROM sometable;
queries. Since <function>min()</function>,
queries. Since <function>min()</function>,
<function>max()</function>, and <function>count()</function> are
<function>max()</function>, and <function>count()</function> are
defined using a generic API for aggregate functions, there is no
defined using a generic API for aggregate functions, there is no
provision for
<quote>special-casing</quote> the execution of these
provision for
special-casing the execution of these functions
functions
under certain circumstances.
under certain circumstances.
</para>
</para>
<para>
<para>
...
...
doc/src/sgml/install-win32.sgml
View file @
1d27de4c
<!--
<!--
$Header: /cvsroot/pgsql/doc/src/sgml/install-win32.sgml,v 1.1
4 2003/09/30 01:26:29 tgl
Exp $
$Header: /cvsroot/pgsql/doc/src/sgml/install-win32.sgml,v 1.1
5 2003/11/04 09:55:38 petere
Exp $
-->
-->
<chapter id="install-win32">
<chapter id="install-win32">
...
@@ -109,27 +109,27 @@ $Header: /cvsroot/pgsql/doc/src/sgml/install-win32.sgml,v 1.14 2003/09/30 01:26:
...
@@ -109,27 +109,27 @@ $Header: /cvsroot/pgsql/doc/src/sgml/install-win32.sgml,v 1.14 2003/09/30 01:26:
<para>
<para>
<application>psql</application> is compiled as a <quote>console
<application>psql</application> is compiled as a <quote>console
application</>. As
application</>. As the Win32 console windows use a different
the Win32 console windows use a different encoding than the rest of the
encoding than the rest of the system, you must take special care
system, you must take special care when using 8-bit characters (eg. German
when using 8-bit characters at the <application>psql</application>
umlauts) at the <application>psql</application> prompt. When
prompt. When <application>psql</application> detects a problematic
<application>psql</application> detects a problematic console codepage, it
console code page, it will warn you at startup. To change the
will warn you at startup. To change the console codepage, two things are
console code page, two things are neccessary:
neccessary:
<itemizedlist>
<itemizedlist>
<listitem>
<listitem>
<para>
<para>
Set the codepage with <userinput>cmd.exe /c chcp 1252</userinput>
Set the code page by entering <userinput>cmd.exe /c chcp
(1252 is the German value, replace it with your value). If you are using
1252</userinput>. (1252 is a code page that is appropriate for
cygwin, you can put this command in <filename>/etc/profile</filename>.
German; replace it with your value.) If you are using Cygwin,
you can put this command in <filename>/etc/profile</filename>.
</para>
</para>
</listitem>
</listitem>
<listitem>
<listitem>
<para>
<para>
Set the console font to <quote>Lucida Console</>, because the
raster font
Set the console font to <quote>Lucida Console</>, because the
does not work with the ANSI code
page.
raster font does not work with the ANSI code
page.
</para>
</para>
</listitem>
</listitem>
</itemizedlist>
</itemizedlist>
...
...
doc/src/sgml/installation.sgml
View file @
1d27de4c
<!-- $Header: /cvsroot/pgsql/doc/src/sgml/installation.sgml,v 1.17
7 2003/11/02 12:57:4
8 petere Exp $ -->
<!-- $Header: /cvsroot/pgsql/doc/src/sgml/installation.sgml,v 1.17
8 2003/11/04 09:55:3
8 petere Exp $ -->
<chapter id="installation">
<chapter id="installation">
<title><![%standalone-include[<productname>PostgreSQL</>]]>
<title><![%standalone-include[<productname>PostgreSQL</>]]>
...
@@ -333,7 +333,7 @@ JAVACMD=$JAVA_HOME/bin/java
...
@@ -333,7 +333,7 @@ JAVACMD=$JAVA_HOME/bin/java
<para>
<para>
The <productname>PostgreSQL</> &version; sources can be obtained by
The <productname>PostgreSQL</> &version; sources can be obtained by
anonymous FTP from <ulink
anonymous FTP from <ulink
url="ftp://ftp.postgresql.org/pub/postgresql-&version;.tar.gz"></ulink>.
url="ftp://ftp.postgresql.org/pub/
source/v&version;/
postgresql-&version;.tar.gz"></ulink>.
Use a mirror if possible. After you have obtained the file, unpack it:
Use a mirror if possible. After you have obtained the file, unpack it:
<screen>
<screen>
<userinput>gunzip postgresql-&version;.tar.gz</userinput>
<userinput>gunzip postgresql-&version;.tar.gz</userinput>
...
@@ -903,10 +903,11 @@ JAVACMD=$JAVA_HOME/bin/java
...
@@ -903,10 +903,11 @@ JAVACMD=$JAVA_HOME/bin/java
<term><option>--disable-spinlocks</option></term>
<term><option>--disable-spinlocks</option></term>
<listitem>
<listitem>
<para>
<para>
Allows source builds to succeed without CPU spinlock support.
Allow the builds to succeed even if PostgreSQL has no CPU
Lack of spinlock support will produce poor performance.
spinlock support for the platform. The lack of spinlock
This option is to be used only by platforms lacking
support will result in poor performance; therefore, this
spinlock support.
option should only be used if the build aborts and informs
you that the platform lacks spinlock support.
</para>
</para>
</listitem>
</listitem>
</varlistentry>
</varlistentry>
...
@@ -915,9 +916,10 @@ JAVACMD=$JAVA_HOME/bin/java
...
@@ -915,9 +916,10 @@ JAVACMD=$JAVA_HOME/bin/java
<term><option>--enable-thread-safety</option></term>
<term><option>--enable-thread-safety</option></term>
<listitem>
<listitem>
<para>
<para>
Allow separate threads in <application>libpq</application>
Make the client libraries thread-safe. This allows
and <application>ECPG</application> programs to safely
concurrent threads in <application>libpq</application> and
control their private connection handles.
<application>ECPG</application> programs to safely control
their private connection handles.
</para>
</para>
</listitem>
</listitem>
</varlistentry>
</varlistentry>
...
@@ -1040,8 +1042,6 @@ All of PostgreSQL is successfully made. Ready to install.
...
@@ -1040,8 +1042,6 @@ All of PostgreSQL is successfully made. Ready to install.
<userinput>gmake check</userinput>
<userinput>gmake check</userinput>
</screen>
</screen>
(This won't work as root; do it as an unprivileged user.)
(This won't work as root; do it as an unprivileged user.)
It is possible that some tests fail, due to differences in error
message wording or floating point results.
<![%standalone-include[The file
<![%standalone-include[The file
<filename>src/test/regress/README</> and the
<filename>src/test/regress/README</> and the
documentation contain]]>
documentation contain]]>
...
@@ -1156,28 +1156,6 @@ All of PostgreSQL is successfully made. Ready to install.
...
@@ -1156,28 +1156,6 @@ All of PostgreSQL is successfully made. Ready to install.
<sect1 id="install-post">
<sect1 id="install-post">
<title>Post-Installation Setup</title>
<title>Post-Installation Setup</title>
<sect2>
<title>Tuning</title>
<indexterm>
<primary>tuning</primary>
</indexterm>
<para>
By default, <productname>PostgreSQL</> is configured to run on minimal
hardware. This allows it to start up with almost any hardware
configuration. However, the default configuration is not designed for
optimum performance. To achieve optimum performance, several server
variables must be adjusted, the two most common being
<varname>shared_buffers</varname> and <varname> sort_mem</varname>
mentioned in <![%standalone-include[the documentation]]>
<![%standalone-ignore[<xref linkend="runtime-config-resource-memory">]]>.
Other parameters in <![%standalone-include[the documentation]]>
<![%standalone-ignore[<xref linkend="runtime-config-resource">]]>
also affect performance.
</para>
</sect2>
<sect2>
<sect2>
<title>Shared Libraries</title>
<title>Shared Libraries</title>
...
@@ -1458,39 +1436,28 @@ kill `cat /usr/local/pgsql/data/postmaster.pid`
...
@@ -1458,39 +1436,28 @@ kill `cat /usr/local/pgsql/data/postmaster.pid`
<listitem>
<listitem>
<para>
<para>
Run the regression tests against the installed server (using
the
Run the regression tests against the installed server (using
sequential test method). If you didn't run the tests befor
e
<command>gmake installcheck</command>). If you didn't run th
e
installation, you should definitely do it now. This is also
tests before installation, you should definitely do it now. This
explained in the documentation.
is also
explained in the documentation.
</para>
</para>
</listitem>
</listitem>
</itemizedlist>
<listitem>
</para>
<!-- do we still ship this? -->
<!--
<para>
<para>
The documentation is also available in Postscript format. If you
By default, <productname>PostgreSQL</> is configured to run on
have a Postscript printer, or have your machine already set up to
minimal hardware. This allows it to start up with almost any
accept Postscript files using a print filter, then to print, the
hardware configuration. The default configuration is, however,
documentation simply type
not designed for optimum performance. To achieve optimum
<programlisting>
performance, several server parameters must be adjusted, the two
cd /usr/local/pgsql/doc
most common being <varname>shared_buffers</varname> and
gunzip -c postgres.ps.gz | lpr
<varname> sort_mem</varname> mentioned in the documentation.
</programlisting>
Other parameters mentioned in the documentation also affect
Here is how you might do it if you have <productname>Ghostscript</>
performance.
installed on your system and are writing to a Laserjet printer.
</para>
<programlisting>
</listitem>
gunzip -c postgres.ps.gz \
</itemizedlist>
| gs -sDEVICE=laserjet -r300 -q -dNOPAUSE -sOutputFile=- \
| lpr
</programlisting>
Printer setups can vary wildly from system to system. If in doubt,
consult your manuals or your local expert.
</para>
</para>
-->
</sect1>
</sect1>
]]>
]]>
...
@@ -1624,14 +1591,6 @@ gunzip -c postgres.ps.gz \
...
@@ -1624,14 +1591,6 @@ gunzip -c postgres.ps.gz \
Jani Averbach (<email>jaa@cc.jyu.fi</email>)</entry>
Jani Averbach (<email>jaa@cc.jyu.fi</email>)</entry>
<entry>2.6</entry>
<entry>2.6</entry>
</row>
</row>
<row>
<entry><systemitem class="osname">Linux</></entry>
<entry><systemitem>PlayStation 2</></entry>
<entry>7.3</entry>
<entry>2002-11-19,
Permaine Cheung <email>pcheung@redhat.com</email>)</entry>
<entry><literal>#undef HAS_TEST_AND_SET</>, remove <type>slock_t</> <literal>typedef</></entry>
</row>
<row>
<row>
<entry><systemitem class="osname">Linux</></entry>
<entry><systemitem class="osname">Linux</></entry>
<entry><systemitem>PPC</></entry>
<entry><systemitem>PPC</></entry>
...
@@ -1706,7 +1665,7 @@ gunzip -c postgres.ps.gz \
...
@@ -1706,7 +1665,7 @@ gunzip -c postgres.ps.gz \
<entry>3.2</entry>
<entry>3.2</entry>
</row>
</row>
<row>
<row>
<entry><systemitem class="osname">SCO OpenServer
5
</></entry>
<entry><systemitem class="osname">SCO OpenServer</></entry>
<entry><systemitem>x86</></entry>
<entry><systemitem>x86</></entry>
<entry>7.3.1</entry>
<entry>7.3.1</entry>
<entry>2002-12-11,
<entry>2002-12-11,
...
@@ -1804,6 +1763,26 @@ gunzip -c postgres.ps.gz \
...
@@ -1804,6 +1763,26 @@ gunzip -c postgres.ps.gz \
Cyril Velter (<email>cyril.velter@libertysurf.fr</email>)</entry>
Cyril Velter (<email>cyril.velter@libertysurf.fr</email>)</entry>
<entry>needs updates to semaphore code</entry>
<entry>needs updates to semaphore code</entry>
</row>
</row>
<row>
<entry><systemitem class="osname">Linux</></entry>
<entry><systemitem>PlayStation 2</></entry>
<entry>7.4</entry>
<entry>2003-11-02,
Peter Eisentraut <email>peter_e@gmx.net</email>)</entry>
<entry>
needs new <filename>config.guess</filename>,
<option>--disable-spinlock</option>, <literal>#undef
HAS_TEST_AND_SET</>, disable <function>tas_dummy()</>
</entry>
</row>
<row>
<entry><systemitem class="osname">Linux</></entry>
<entry><systemitem>PA-RISC</></entry>
<entry>7.4</entry>
<entry>2003-10-25,
Noèl Köthe (<email>noel@debian.org</email>)</entry>
<entry>needs <option>--disable-spinlock</option>, otherwise OK</entry>
</row>
<row>
<row>
<entry><systemitem class="osname">NetBSD</></entry>
<entry><systemitem class="osname">NetBSD</></entry>
<entry><systemitem>Alpha</></entry>
<entry><systemitem>Alpha</></entry>
...
...
doc/src/sgml/maintenance.sgml
View file @
1d27de4c
<!--
<!--
$Header: /cvsroot/pgsql/doc/src/sgml/maintenance.sgml,v 1.2
7 2003/11/01 01:56:29
petere Exp $
$Header: /cvsroot/pgsql/doc/src/sgml/maintenance.sgml,v 1.2
8 2003/11/04 09:55:38
petere Exp $
-->
-->
<chapter id="maintenance">
<chapter id="maintenance">
...
@@ -40,10 +40,10 @@ $Header: /cvsroot/pgsql/doc/src/sgml/maintenance.sgml,v 1.27 2003/11/01 01:56:29
...
@@ -40,10 +40,10 @@ $Header: /cvsroot/pgsql/doc/src/sgml/maintenance.sgml,v 1.27 2003/11/01 01:56:29
</para>
</para>
<para>
<para>
<productname>PostgreSQL</productname> is low-maintenance compared
to
<productname>PostgreSQL</productname> is low-maintenance compared
some other database products. Nonetheless, appropriate attention to
to some other database management systems. Nonetheless,
these tasks will go far towards ensuring a pleasant and productive
appropriate attention to these tasks will go far towards ensuring a
experience with the system.
pleasant and productive
experience with the system.
</para>
</para>
<sect1 id="routine-vacuuming">
<sect1 id="routine-vacuuming">
...
...
doc/src/sgml/monitoring.sgml
View file @
1d27de4c
<!--
<!--
$Header: /cvsroot/pgsql/doc/src/sgml/monitoring.sgml,v 1.2
3 2003/11/01 01:56:29
petere Exp $
$Header: /cvsroot/pgsql/doc/src/sgml/monitoring.sgml,v 1.2
4 2003/11/04 09:55:38
petere Exp $
-->
-->
<chapter id="monitoring">
<chapter id="monitoring">
...
@@ -367,12 +367,13 @@ postgres: <replaceable>user</> <replaceable>database</> <replaceable>host</> <re
...
@@ -367,12 +367,13 @@ postgres: <replaceable>user</> <replaceable>database</> <replaceable>host</> <re
queries that use the same underlying statistics access functions as
queries that use the same underlying statistics access functions as
these standard views do. These functions are listed in <xref
these standard views do. These functions are listed in <xref
linkend="monitoring-stats-funcs-table">. The per-database access
linkend="monitoring-stats-funcs-table">. The per-database access
functions take a database OID as argument to identify which database to
functions take a database OID as argument to identify which
report on. The per-table and per-index functions take a table or
database to report on. The per-table and per-index functions take
index OID. (Note that only tables and indexes in the current
a table or index OID. (Note that only tables and indexes in the
database can be seen with these functions.) The per-backend access
current database can be seen with these functions.) The
functions take a backend ID number, which ranges from one to the
per-backend process access functions take a backend process ID
number of currently active backend processes.
number, which ranges from one to the number of currently active
backend processes.
</para>
</para>
<table id="monitoring-stats-funcs-table">
<table id="monitoring-stats-funcs-table">
...
...
doc/src/sgml/mvcc.sgml
View file @
1d27de4c
<!--
<!--
$Header: /cvsroot/pgsql/doc/src/sgml/mvcc.sgml,v 2.
39 2003/10/17 22:38:20 tgl
Exp $
$Header: /cvsroot/pgsql/doc/src/sgml/mvcc.sgml,v 2.
40 2003/11/04 09:55:38 petere
Exp $
-->
-->
<chapter id="mvcc">
<chapter id="mvcc">
...
@@ -770,22 +770,17 @@ UPDATE accounts SET balance = balance - 100.00 WHERE acctnum = 22222;
...
@@ -770,22 +770,17 @@ UPDATE accounts SET balance = balance - 100.00 WHERE acctnum = 22222;
<para>
<para>
To ensure the current validity of a row and protect it against
To ensure the current validity of a row and protect it against
concurrent updates one must use <command>SELECT FOR
UPDATE</command> or
concurrent updates one must use <command>SELECT FOR
an appropriate <command>LOCK TABLE</command> statement.
UPDATE</command> or an appropriate <command>LOCK TABLE</command>
(<command>SELECT FOR UPDATE</command> locks just the returned rows against
statement. (<command>SELECT FOR UPDATE</command> locks just the
concurrent updates, while <command>LOCK TABLE</command> locks the
returned rows against concurrent updates, while <command>LOCK
whole table.)
TABLE</command> locks the whole table.) This should be taken into
This should be taken into
account when porting applications to
account when porting applications to
<productname>PostgreSQL</productname> from other environments.
<productname>PostgreSQL</productname> from other environments.
(Before version 6.5 <productname>PostgreSQL</productname> used
<note>
read locks, and so this above consideration is also relevant when
<para>
Before version 6.5 <productname>PostgreSQL</productname> used
read locks, and so the above consideration is also the case when
upgrading from <productname>PostgreSQL</productname> versions
upgrading from <productname>PostgreSQL</productname> versions
prior to 6.5.
prior to 6.5.)
</para>
</note>
</para>
</para>
<para>
<para>
...
...
doc/src/sgml/postgres.sgml
View file @
1d27de4c
<!--
<!--
$Header: /cvsroot/pgsql/doc/src/sgml/postgres.sgml,v 1.
59 2003/10/23 13:58:43 tgl
Exp $
$Header: /cvsroot/pgsql/doc/src/sgml/postgres.sgml,v 1.
60 2003/11/04 09:55:38 petere
Exp $
-->
-->
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook V3.1//EN" [
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook V3.1//EN" [
...
@@ -84,7 +84,7 @@ $Header: /cvsroot/pgsql/doc/src/sgml/postgres.sgml,v 1.59 2003/10/23 13:58:43 tg
...
@@ -84,7 +84,7 @@ $Header: /cvsroot/pgsql/doc/src/sgml/postgres.sgml,v 1.59 2003/10/23 13:58:43 tg
</para>
</para>
<para>
<para>
Readers of this
book
should know how to connect to a
Readers of this
part
should know how to connect to a
<productname>PostgreSQL</> database and issue
<productname>PostgreSQL</> database and issue
<acronym>SQL</acronym> commands. Readers that are unfamiliar with
<acronym>SQL</acronym> commands. Readers that are unfamiliar with
these issues are encouraged to read <xref linkend="tutorial">
these issues are encouraged to read <xref linkend="tutorial">
...
...
doc/src/sgml/queries.sgml
View file @
1d27de4c
<!-- $Header: /cvsroot/pgsql/doc/src/sgml/queries.sgml,v 1.2
5 2003/11/01 01:56:29
petere Exp $ -->
<!-- $Header: /cvsroot/pgsql/doc/src/sgml/queries.sgml,v 1.2
6 2003/11/04 09:55:38
petere Exp $ -->
<chapter id="queries">
<chapter id="queries">
<title>Queries</title>
<title>Queries</title>
...
@@ -105,7 +105,7 @@ SELECT random();
...
@@ -105,7 +105,7 @@ SELECT random();
</para>
</para>
<sect2 id="queries-from">
<sect2 id="queries-from">
<title>The
FROM
Clause</title>
<title>The
<literal>FROM</literal>
Clause</title>
<para>
<para>
The <literal>FROM</> clause derives a table from one or more other
The <literal>FROM</> clause derives a table from one or more other
...
@@ -670,7 +670,7 @@ SELECT *
...
@@ -670,7 +670,7 @@ SELECT *
</sect2>
</sect2>
<sect2 id="queries-where">
<sect2 id="queries-where">
<title>The
WHERE
Clause</title>
<title>The
<literal>WHERE</literal>
Clause</title>
<indexterm zone="queries-where">
<indexterm zone="queries-where">
<primary>WHERE</primary>
<primary>WHERE</primary>
...
@@ -716,7 +716,7 @@ FROM a NATURAL JOIN b WHERE b.val > 5
...
@@ -716,7 +716,7 @@ FROM a NATURAL JOIN b WHERE b.val > 5
</programlisting>
</programlisting>
Which one of these you use is mainly a matter of style. The
Which one of these you use is mainly a matter of style. The
<literal>JOIN</> syntax in the <literal>FROM</> clause is
<literal>JOIN</> syntax in the <literal>FROM</> clause is
probably not as portable to other SQL database
product
s. For
probably not as portable to other SQL database
management system
s. For
outer joins there is no choice in any case: they must be done in
outer joins there is no choice in any case: they must be done in
the <literal>FROM</> clause. An <literal>ON</>/<literal>USING</>
the <literal>FROM</> clause. An <literal>ON</>/<literal>USING</>
clause of an outer join is <emphasis>not</> equivalent to a
clause of an outer join is <emphasis>not</> equivalent to a
...
@@ -758,7 +758,7 @@ SELECT ... FROM fdt WHERE EXISTS (SELECT c1 FROM t2 WHERE c2 > fdt.c1)
...
@@ -758,7 +758,7 @@ SELECT ... FROM fdt WHERE EXISTS (SELECT c1 FROM t2 WHERE c2 > fdt.c1)
<sect2 id="queries-group">
<sect2 id="queries-group">
<title>The
GROUP BY and HAVING
Clauses</title>
<title>The
<literal>GROUP BY</literal> and <literal>HAVING</literal>
Clauses</title>
<indexterm zone="queries-group">
<indexterm zone="queries-group">
<primary>GROUP BY</primary>
<primary>GROUP BY</primary>
...
@@ -1040,7 +1040,7 @@ SELECT a AS value, b + c AS sum FROM ...
...
@@ -1040,7 +1040,7 @@ SELECT a AS value, b + c AS sum FROM ...
</sect2>
</sect2>
<sect2 id="queries-distinct">
<sect2 id="queries-distinct">
<title>
DISTINCT
</title>
<title>
<literal>DISTINCT</literal>
</title>
<indexterm zone="queries-distinct">
<indexterm zone="queries-distinct">
<primary>DISTINCT</primary>
<primary>DISTINCT</primary>
...
@@ -1264,7 +1264,7 @@ SELECT a AS b FROM table1 ORDER BY a;
...
@@ -1264,7 +1264,7 @@ SELECT a AS b FROM table1 ORDER BY a;
<sect1 id="queries-limit">
<sect1 id="queries-limit">
<title>
LIMIT and OFFSET
</title>
<title>
<literal>LIMIT</literal> and <literal>OFFSET</literal>
</title>
<indexterm zone="queries-limit">
<indexterm zone="queries-limit">
<primary>LIMIT</primary>
<primary>LIMIT</primary>
...
...
doc/src/sgml/ref/pg_dump.sgml
View file @
1d27de4c
<!--
<!--
$Header: /cvsroot/pgsql/doc/src/sgml/ref/pg_dump.sgml,v 1.6
5 2003/09/23 22:48:53 tgl
Exp $
$Header: /cvsroot/pgsql/doc/src/sgml/ref/pg_dump.sgml,v 1.6
6 2003/11/04 09:55:39 petere
Exp $
PostgreSQL documentation
PostgreSQL documentation
-->
-->
...
@@ -177,7 +177,7 @@ PostgreSQL documentation
...
@@ -177,7 +177,7 @@ PostgreSQL documentation
Dump data as <command>INSERT</command> commands (rather
Dump data as <command>INSERT</command> commands (rather
than <command>COPY</command>). This will make restoration very
than <command>COPY</command>). This will make restoration very
slow, but it makes the archives more portable to other SQL database
slow, but it makes the archives more portable to other SQL database
package
s.
management system
s.
</para>
</para>
</listitem>
</listitem>
</varlistentry>
</varlistentry>
...
...
doc/src/sgml/ref/pg_dumpall.sgml
View file @
1d27de4c
<!--
<!--
$Header: /cvsroot/pgsql/doc/src/sgml/ref/pg_dumpall.sgml,v 1.4
1 2003/11/02 12:58
:39 petere Exp $
$Header: /cvsroot/pgsql/doc/src/sgml/ref/pg_dumpall.sgml,v 1.4
2 2003/11/04 09:55
:39 petere Exp $
PostgreSQL documentation
PostgreSQL documentation
-->
-->
...
@@ -112,7 +112,7 @@ PostgreSQL documentation
...
@@ -112,7 +112,7 @@ PostgreSQL documentation
Dump data as <command>INSERT</command> commands (rather
Dump data as <command>INSERT</command> commands (rather
than <command>COPY</command>). This will make restoration very
than <command>COPY</command>). This will make restoration very
slow, but it makes the output more portable to other SQL database
slow, but it makes the output more portable to other SQL database
package
s.
management system
s.
</para>
</para>
</listitem>
</listitem>
</varlistentry>
</varlistentry>
...
...
doc/src/sgml/regress.sgml
View file @
1d27de4c
<!-- $Header: /cvsroot/pgsql/doc/src/sgml/regress.sgml,v 1.3
5 2003/11/02 21:56:14 tgl
Exp $ -->
<!-- $Header: /cvsroot/pgsql/doc/src/sgml/regress.sgml,v 1.3
6 2003/11/04 09:55:38 petere
Exp $ -->
<chapter id="regress">
<chapter id="regress">
<title id="regress-title">Regression Tests</title>
<title id="regress-title">Regression Tests</title>
...
@@ -60,7 +60,6 @@ gmake check
...
@@ -60,7 +60,6 @@ gmake check
linkend="regress-evaluation"> below for more.
linkend="regress-evaluation"> below for more.
</para>
</para>
<note>
<para>
<para>
Because this test method runs a temporary server, it will not work
Because this test method runs a temporary server, it will not work
when you are the root user (since the server will not start as root).
when you are the root user (since the server will not start as root).
...
@@ -82,9 +81,7 @@ gmake check
...
@@ -82,9 +81,7 @@ gmake check
<para>
<para>
Alternatively, run the tests after installation.
Alternatively, run the tests after installation.
</para>
</para>
</note>
<tip>
<para>
<para>
The parallel regression test starts quite a few processes under your
The parallel regression test starts quite a few processes under your
user ID. Presently, the maximum concurrency is twenty parallel test
user ID. Presently, the maximum concurrency is twenty parallel test
...
@@ -101,9 +98,7 @@ gmake MAX_CONNECTIONS=10 check
...
@@ -101,9 +98,7 @@ gmake MAX_CONNECTIONS=10 check
</screen>
</screen>
runs no more than ten tests concurrently.
runs no more than ten tests concurrently.
</para>
</para>
</tip>
<tip>
<para>
<para>
On some systems, the default Bourne-compatible shell
On some systems, the default Bourne-compatible shell
(<filename>/bin/sh</filename>) gets confused when it has to manage
(<filename>/bin/sh</filename>) gets confused when it has to manage
...
@@ -116,7 +111,6 @@ gmake SHELL=/bin/ksh check
...
@@ -116,7 +111,6 @@ gmake SHELL=/bin/ksh check
If no non-broken shell is available, you may be able to work around the
If no non-broken shell is available, you may be able to work around the
problem by limiting the number of connections, as shown above.
problem by limiting the number of connections, as shown above.
</para>
</para>
</tip>
<para>
<para>
To run the tests after installation<![%standalone-ignore;[ (see <xref linkend="installation">)]]>,
To run the tests after installation<![%standalone-ignore;[ (see <xref linkend="installation">)]]>,
...
@@ -223,9 +217,9 @@ gmake installcheck
...
@@ -223,9 +217,9 @@ gmake installcheck
<note>
<note>
<para>
<para>
Because USA daylight-saving rules are used, this problem always
Because USA daylight-saving
time
rules are used, this problem always
occurs on the first Sunday of April, the last Sunday of October,
occurs on the first Sunday of April, the last Sunday of October,
and their following Mondays, regardless of when daylight-saving
and their following Mondays, regardless of when daylight-saving
time
is in effect where you live. Also note that the problem appears or
is in effect where you live. Also note that the problem appears or
disappears at midnight Pacific time (UTC-7 or UTC-8), not midnight
disappears at midnight Pacific time (UTC-7 or UTC-8), not midnight
your local time. Thus the failure may appear late on Saturday or
your local time. Thus the failure may appear late on Saturday or
...
...
doc/src/sgml/runtime.sgml
View file @
1d27de4c
<!--
<!--
$Header: /cvsroot/pgsql/doc/src/sgml/runtime.sgml,v 1.21
5 2003/11/01 01:56:29
petere Exp $
$Header: /cvsroot/pgsql/doc/src/sgml/runtime.sgml,v 1.21
6 2003/11/04 09:55:38
petere Exp $
-->
-->
<Chapter Id="runtime">
<Chapter Id="runtime">
...
@@ -174,7 +174,7 @@ $ <userinput>postmaster -D /usr/local/pgsql/data</userinput>
...
@@ -174,7 +174,7 @@ $ <userinput>postmaster -D /usr/local/pgsql/data</userinput>
To start the <command>postmaster</command> in the
To start the <command>postmaster</command> in the
background, use the usual shell syntax:
background, use the usual shell syntax:
<screen>
<screen>
$ <userinput>postmaster -D /usr/local/pgsql/data >
logfile 2>&1 &</userinput>
$ <userinput>postmaster -D /usr/local/pgsql/data >logfile 2>&1 &</userinput>
</screen>
</screen>
It is an important to store the server's <systemitem>stdout</> and
It is an important to store the server's <systemitem>stdout</> and
<systemitem>stderr</> output somewhere, as shown above. It will help
<systemitem>stderr</> output somewhere, as shown above. It will help
...
@@ -344,7 +344,7 @@ FATAL: could not create TCP/IP listen socket
...
@@ -344,7 +344,7 @@ FATAL: could not create TCP/IP listen socket
A message like
A message like
<screen>
<screen>
FATAL: could not create shared memory segment: Invalid argument
FATAL: could not create shared memory segment: Invalid argument
DETAIL: Failed syscall was shmget(key=5440001, size=4011376640, 03600).
DETAIL: Failed sys
tem
call was shmget(key=5440001, size=4011376640, 03600).
</screen>
</screen>
probably means your kernel's limit on the size of shared memory is
probably means your kernel's limit on the size of shared memory is
smaller than the work area <productname>PostgreSQL</productname>
smaller than the work area <productname>PostgreSQL</productname>
...
@@ -363,7 +363,7 @@ DETAIL: Failed syscall was shmget(key=5440001, size=4011376640, 03600).
...
@@ -363,7 +363,7 @@ DETAIL: Failed syscall was shmget(key=5440001, size=4011376640, 03600).
An error like
An error like
<screen>
<screen>
FATAL: could not create semaphores: No space left on device
FATAL: could not create semaphores: No space left on device
DETAIL: Failed syscall was semget(5440126, 17, 03600).
DETAIL: Failed sys
tem
call was semget(5440126, 17, 03600).
</screen>
</screen>
does <emphasis>not</emphasis> mean you've run out of disk
does <emphasis>not</emphasis> mean you've run out of disk
space. It means your kernel's limit on the number of <systemitem
space. It means your kernel's limit on the number of <systemitem
...
@@ -2993,9 +2993,10 @@ options SEMMAP=256
...
@@ -2993,9 +2993,10 @@ options SEMMAP=256
<literal>option</literal> singular.)
<literal>option</literal> singular.)
</para>
</para>
<para>
<para>
You might also want to use the <command>sysctl</> setting to
You might also want to configure your kernel to lock shared
lock shared memory into RAM and prevent it from being paged out
memory into RAM and prevent it from being paged out to swap.
to swap, e.g. <literal>kern.ipc.shm_use_phys</>.
Use the <command>sysctl</> setting
<literal>kern.ipc.shm_use_phys</>.
</para>
</para>
</listitem>
</listitem>
</varlistentry>
</varlistentry>
...
@@ -3059,65 +3060,6 @@ kernel.shmmax = 134217728
...
@@ -3059,65 +3060,6 @@ kernel.shmmax = 134217728
<filename>/usr/src/linux/include/asm-<replaceable>xxx</>/shmpara
<filename>/usr/src/linux/include/asm-<replaceable>xxx</>/shmpara
m.h</> and <filename>/usr/src/linux/include/linux/sem.h</>.
m.h</> and <filename>/usr/src/linux/include/linux/sem.h</>.
</para>
</para>
<para>
Linux kernel version 2.4.* has poor default memory overcommit
behavior, which can result in the postmaster being killed by the
kernel due to memory demands by another process if the system
runs out of memory.
</para>
<para>
The symptom of this occurring is a kernel message looking like
this (consult your system documentation and configuration on
where to look for such a message):
<programlisting>
Out of Memory: Killed process 12345 (postmaster).
</programlisting>
</para>
<para>
To avoid this situation, run <productname>PostgreSQL</productname>
on a machine where you
can be sure that other processes will not run the machine out
of memory. If your kernel supports strict and/or paranoid modes
of overcommit handling, you can also relieve this problem by
altering the system's default behaviour. This can be determined
by examining the function <function>vm_enough_memory</>
in the file <filename>mm/mmap.c</> in the kernel source.
If this file reveals that strict and/or paranoid modes are
supported by your kernel, turn one of these modes on by using
<programlisting>
sysctl -w vm.overcommit_memory=2
</programlisting>
for strict mode or
<programlisting>
sysctl -w vm.overcommit_memory=3
</programlisting>
for paranoid mode, or placing an equivalent entry in
<filename>/etc/sysctl.conf</>.
</para>
<note>
<para>
Warning: using these settings in a kernel which does not support
these modes will almost certainly increase the danger of the
kernel killing the postmaster, rather than reducing it.
If in any doubt, consult a kernel expert or your kernel vendor.
</para>
</note>
<para>
These modes are expected to be supported in all 2.6 and later
kernels. Some vendor 2.4 kernels may also support these modes.
However, it is known that some vendor documents suggest that
they support them while examination of the kernel source reveals
that they do not.
</para>
<para>
Note, you will need enough swap space to cover all your memory needs.
</para>
</listitem>
</listitem>
</varlistentry>
</varlistentry>
...
@@ -3319,6 +3261,71 @@ default:\
...
@@ -3319,6 +3261,71 @@ default:\
</para>
</para>
</sect2>
</sect2>
<sect2>
<title>Linux Memory Overcommit</title>
<para>
Linux kernels of version 2.4.* have a poor default memory
overcommit behavior, which can result in the PostgreSQL server
(<filename>postmaster</filename> process) being killed by the
kernel if the memory demands of another process cause the system
to run out of memory.
</para>
<para>
If this happens, you will see a kernel message looking like this
(consult your system documentation and configuration on where to
look for such a message):
<programlisting>
Out of Memory: Killed process 12345 (postmaster).
</programlisting>
And, of course, you will find that your database server has
disappeared.
</para>
<para>
To avoid this situation, run <productname>PostgreSQL</productname>
on a machine where you can be sure that other processes will not
run the machine out of memory. If your kernel supports the strict
and/or paranoid modes of overcommit handling, you can also relieve
this problem by altering the system's default behaviour. This can
be determined by examining the function
<function>vm_enough_memory</> in the file <filename>mm/mmap.c</>
in the kernel source. If this file reveals that the strict and/or
paranoid modes are supported by your kernel, turn one of these
modes on by using
<programlisting>
sysctl -w vm.overcommit_memory=2
</programlisting>
for strict mode, or
<programlisting>
sysctl -w vm.overcommit_memory=3
</programlisting>
for paranoid mode, or placing an equivalent entry in
<filename>/etc/sysctl.conf</>.
</para>
<caution>
<para>
Using these settings in a kernel which does not support these
modes will almost certainly increase the danger of the kernel
killing the database server, rather than reducing it. If in any
doubt, consult a kernel expert or your kernel vendor.
</para>
</caution>
<para>
These modes are expected to be supported in all 2.6 and later
kernels. Some vendor 2.4 kernels may also support these modes. It
is, however, known that some vendor documents suggest that they
support them while examination of the kernel source reveals that
they do not.
</para>
<para>
Note, you will need enough swap space to cover all your memory needs.
</para>
</sect2>
</sect1>
</sect1>
...
...
doc/src/sgml/syntax.sgml
View file @
1d27de4c
<!--
<!--
$Header: /cvsroot/pgsql/doc/src/sgml/syntax.sgml,v 1.8
5 2003/11/01 01:56:2
9 petere Exp $
$Header: /cvsroot/pgsql/doc/src/sgml/syntax.sgml,v 1.8
6 2003/11/04 09:55:3
9 petere Exp $
-->
-->
<chapter id="sql-syntax">
<chapter id="sql-syntax">
...
@@ -196,20 +196,16 @@ UPDATE "my_table" SET "a" = 5;
...
@@ -196,20 +196,16 @@ UPDATE "my_table" SET "a" = 5;
unquoted names are always folded to lower case. For example, the
unquoted names are always folded to lower case. For example, the
identifiers <literal>FOO</literal>, <literal>foo</literal>, and
identifiers <literal>FOO</literal>, <literal>foo</literal>, and
<literal>"foo"</literal> are considered the same by
<literal>"foo"</literal> are considered the same by
<productname>PostgreSQL</productname>, but <literal>"Foo"</literal>
<productname>PostgreSQL</productname>, but
and <literal>"FOO"</literal> are different from these three and
<literal>"Foo"</literal> and <literal>"FOO"</literal> are
each other.
different from these three and each other. (The folding of
<footnote>
unquoted names to lower case in <productname>PostgreSQL</> is
<para>
incompatible with the SQL standard, which says that unquoted names
The folding of unquoted names to lower case in <productname>PostgreSQL</>
should be folded to upper case. Thus, <literal>foo</literal>
is incompatible with the SQL standard, which says that unquoted
names should be folded to upper case. Thus, <literal>foo</literal>
should be equivalent to <literal>"FOO"</literal> not
should be equivalent to <literal>"FOO"</literal> not
<literal>"foo"</literal> according to the standard. If you want to
<literal>"foo"</literal> according to the standard. If you want
write portable applications you are advised to always quote a particular
to write portable applications you are advised to always quote a
name or never quote it.
particular name or never quote it.
</para>
</footnote>
</para>
</para>
</sect2>
</sect2>
...
@@ -260,10 +256,12 @@ UPDATE "my_table" SET "a" = 5;
...
@@ -260,10 +256,12 @@ UPDATE "my_table" SET "a" = 5;
form feed, <literal>\n</literal> is a newline,
form feed, <literal>\n</literal> is a newline,
<literal>\r</literal> is a carriage return, <literal>\t</literal>
<literal>\r</literal> is a carriage return, <literal>\t</literal>
is a tab, and <literal>\<replaceable>xxx</replaceable></literal>,
is a tab, and <literal>\<replaceable>xxx</replaceable></literal>,
where <replaceable>xxx</replaceable> is an octal number, is the
where <replaceable>xxx</replaceable> is an octal number, is a
character with the corresponding ASCII code. Any other character
byte with the corresponding code. (It is your responsibility
following a backslash is taken literally. Thus, to include a
that the byte sequences you create are valid characters in the
backslash in a string constant, type two backslashes.
server character set encoding.) Any other character following a
backslash is taken literally. Thus, to include a backslash in a
string constant, type two backslashes.
</para>
</para>
<para>
<para>
...
@@ -440,44 +438,8 @@ CAST ( '<replaceable>string</replaceable>' AS <replaceable>type</replaceable> )
...
@@ -440,44 +438,8 @@ CAST ( '<replaceable>string</replaceable>' AS <replaceable>type</replaceable> )
or <literal>CAST()</literal> to specify the type of an array constant.
or <literal>CAST()</literal> to specify the type of an array constant.
</para>
</para>
</sect3>
</sect3>
<sect3>
<title>Array constants</title>
<indexterm>
<primary>array</primary>
<secondary>constant</secondary>
</indexterm>
<para>
The general format of an array constant is the following:
<synopsis>
'{ <replaceable>val1</replaceable> <replaceable>delim</replaceable> <replaceable>val2</replaceable> <replaceable>delim</replaceable> ... }'
</synopsis>
where <replaceable>delim</replaceable> is the delimiter character
for the type, as recorded in its <literal>pg_type</literal>
entry. (For all built-in types, this is the comma character
<quote><literal>,</literal></>.) Each <replaceable>val</replaceable> is either a constant
of the array element type, or a subarray. An example of an
array constant is
<programlisting>
'{{1,2,3},{4,5,6},{7,8,9}}'
</programlisting>
This constant is a two-dimensional, 3-by-3 array consisting of three
subarrays of integers. For more information see <xref linkend="arrays">.
</para>
<para>
(Array constants are actually only a special case of the generic
type constants discussed in the previous section. The constant
is initially treated as a string and passed to the array input
conversion routine. An explicit type specification might be
necessary.)
</para>
</sect3>
</sect2>
</sect2>
<sect2 id="sql-syntax-operators">
<sect2 id="sql-syntax-operators">
<title>Operators</title>
<title>Operators</title>
...
@@ -622,7 +584,7 @@ CAST ( '<replaceable>string</replaceable>' AS <replaceable>type</replaceable> )
...
@@ -622,7 +584,7 @@ CAST ( '<replaceable>string</replaceable>' AS <replaceable>type</replaceable> )
A comment is an arbitrary sequence of characters beginning with
A comment is an arbitrary sequence of characters beginning with
double dashes and extending to the end of the line, e.g.:
double dashes and extending to the end of the line, e.g.:
<programlisting>
<programlisting>
-- This is a standard SQL
92
comment
-- This is a standard SQL comment
</programlisting>
</programlisting>
</para>
</para>
...
@@ -635,7 +597,7 @@ CAST ( '<replaceable>string</replaceable>' AS <replaceable>type</replaceable> )
...
@@ -635,7 +597,7 @@ CAST ( '<replaceable>string</replaceable>' AS <replaceable>type</replaceable> )
</programlisting>
</programlisting>
where the comment begins with <literal>/*</literal> and extends to
where the comment begins with <literal>/*</literal> and extends to
the matching occurrence of <literal>*/</literal>. These block
the matching occurrence of <literal>*/</literal>. These block
comments nest, as specified in
SQL99
but unlike C, so that one can
comments nest, as specified in
the SQL standard
but unlike C, so that one can
comment out larger blocks of code that may contain existing block
comment out larger blocks of code that may contain existing block
comments.
comments.
</para>
</para>
...
@@ -1267,7 +1229,7 @@ CAST ( <replaceable>expression</replaceable> AS <replaceable>type</replaceable>
...
@@ -1267,7 +1229,7 @@ CAST ( <replaceable>expression</replaceable> AS <replaceable>type</replaceable>
there is no error; the scalar result is taken to be null.)
there is no error; the scalar result is taken to be null.)
The subquery can refer to variables from the surrounding query,
The subquery can refer to variables from the surrounding query,
which will act as constants during any one evaluation of the subquery.
which will act as constants during any one evaluation of the subquery.
See also <xref linkend="functions-subquery">.
See also <xref linkend="functions-subquery">
for other expressions involving subqueries
.
</para>
</para>
<para>
<para>
...
@@ -1289,7 +1251,7 @@ SELECT name, (SELECT max(pop) FROM cities WHERE cities.state = states.name)
...
@@ -1289,7 +1251,7 @@ SELECT name, (SELECT max(pop) FROM cities WHERE cities.state = states.name)
</indexterm>
</indexterm>
<para>
<para>
An
<firstterm>array constructor</>
is an expression that builds an
An
array constructor
is an expression that builds an
array value from values for its member elements. A simple array
array value from values for its member elements. A simple array
constructor
constructor
consists of the key word <literal>ARRAY</literal>, a left square bracket
consists of the key word <literal>ARRAY</literal>, a left square bracket
...
@@ -1337,11 +1299,11 @@ SELECT ARRAY[[1,2],[3,4]];
...
@@ -1337,11 +1299,11 @@ SELECT ARRAY[[1,2],[3,4]];
an array of the proper kind, not only a sub-<literal>ARRAY</> construct.
an array of the proper kind, not only a sub-<literal>ARRAY</> construct.
For example:
For example:
<programlisting>
<programlisting>
create table
arr(f1 int[], f2 int[]);
CREATE TABLE
arr(f1 int[], f2 int[]);
CREATE TABLE
insert into arr values (ARRAY[[1,2],[3,4]],
ARRAY[[5,6],[7,8]]);
INSERT INTO arr VALUES (ARRAY[[1,2],[3,4]],
ARRAY[[5,6],[7,8]]);
INSERT 2635544 1
select ARRAY[f1, f2, '{{9,10},{11,12}}'::int[]] from
arr;
SELECT ARRAY[f1, f2, '{{9,10},{11,12}}'::int[]] FROM
arr;
array
array
------------------------------------------------
------------------------------------------------
{{{1,2},{3,4}},{{5,6},{7,8}},{{9,10},{11,12}}}
{{{1,2},{3,4}},{{5,6},{7,8}},{{9,10},{11,12}}}
...
@@ -1361,10 +1323,10 @@ SELECT ARRAY(SELECT oid FROM pg_proc WHERE proname LIKE 'bytea%');
...
@@ -1361,10 +1323,10 @@ SELECT ARRAY(SELECT oid FROM pg_proc WHERE proname LIKE 'bytea%');
{2011,1954,1948,1952,1951,1244,1950,2005,1949,1953,2006,31}
{2011,1954,1948,1952,1951,1244,1950,2005,1949,1953,2006,31}
(1 row)
(1 row)
</programlisting>
</programlisting>
The subquery must return a single column. The
The subquery must return a single column. The resulting
resulting
one-dimensional array will have an element for each row in the
one-dimensional array will have an element for each row in the
subquery result, with an element type matching that of the subquery's
subquery result, with an element type matching that of the
output column.
subquery's
output column.
</para>
</para>
<para>
<para>
...
...
doc/src/sgml/typeconv.sgml
View file @
1d27de4c
<!--
<!--
$Header: /cvsroot/pgsql/doc/src/sgml/typeconv.sgml,v 1.3
6 2003/11/01 01:56:2
9 petere Exp $
$Header: /cvsroot/pgsql/doc/src/sgml/typeconv.sgml,v 1.3
7 2003/11/04 09:55:3
9 petere Exp $
-->
-->
<chapter Id="typeconv">
<chapter Id="typeconv">
...
@@ -794,13 +794,14 @@ padding spaces.
...
@@ -794,13 +794,14 @@ padding spaces.
</indexterm>
</indexterm>
<para>
<para>
SQL <literal>UNION</> constructs must match up possibly dissimilar types to
SQL <literal>UNION</> constructs must match up possibly dissimilar
become a single result set. The resolution algorithm is applied separately
types to become a single result set. The resolution algorithm is
to each output column of a union query. The <literal>INTERSECT</> and
applied separately to each output column of a union query. The
<literal>EXCEPT</> constructs resolve dissimilar types in the same way as
<literal>INTERSECT</> and <literal>EXCEPT</> constructs resolve
<literal>UNION</>.
dissimilar types in the same way as <literal>UNION</>. The
A <literal>CASE</> construct uses the identical algorithm to match up its
<literal>CASE</> and <literal>ARRAY</> constructs use the identical
component expressions and select a result data type, as does <literal>ARRAY</>.
algorithm to match up their component expressions and select a result
data type.
</para>
</para>
<procedure>
<procedure>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment