Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit3450fd0

Browse files
committed
More editing of reference pages.
1 parent8a70349 commit3450fd0

21 files changed

+2448
-3499
lines changed

‎doc/src/sgml/ref/create_aggregate.sgml

Lines changed: 163 additions & 201 deletions
Large diffs are not rendered by default.

‎doc/src/sgml/ref/create_cast.sgml

Lines changed: 29 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<!-- $Header: /cvsroot/pgsql/doc/src/sgml/ref/create_cast.sgml,v 1.10 2003/03/25 16:15:39 petere Exp $ -->
1+
<!-- $Header: /cvsroot/pgsql/doc/src/sgml/ref/create_cast.sgml,v 1.11 2003/04/22 10:08:08 petere Exp $ -->
22

33
<refentry id="SQL-CREATECAST">
44
<refmeta>
@@ -58,11 +58,11 @@ SELECT CAST(42 AS text);
5858

5959
<para>
6060
If the cast is marked <literal>AS ASSIGNMENT</> then it can be invoked
61-
implicitly when assigning to a column of the target data type.
61+
implicitly when assigninga valueto a column of the target data type.
6262
For example, supposing that <literal>foo.f1</literal> is a column of
6363
type <type>text</type>, then
6464
<programlisting>
65-
INSERT INTO foo(f1) VALUES(42);
65+
INSERT INTO foo(f1) VALUES(42);
6666
</programlisting>
6767
will be allowed if the cast from type <type>integer</type> to type
6868
<type>text</type> is marked <literal>AS ASSIGNMENT</>, otherwise
@@ -75,7 +75,7 @@ INSERT INTO foo(f1) VALUES(42);
7575
If the cast is marked <literal>AS IMPLICIT</> then it can be invoked
7676
implicitly in any context, whether assignment or internally in an
7777
expression. For example, since <literal>||</> takes <type>text</>
78-
arguments,
78+
operands,
7979
<programlisting>
8080
SELECT 'The time is ' || now();
8181
</programlisting>
@@ -106,14 +106,16 @@ SELECT 'The time is ' || CAST(now() AS text);
106106

107107
<para>
108108
To be able to create a cast, you must own the source or the target
109-
data type. To create a binary-compatible cast, you must be superuser
110-
(this restriction is made because an erroneous binary-compatible cast
111-
conversion can easily crash the server).
109+
data type. To create a binary-compatible cast, you must be superuser.
110+
(This restriction is made because an erroneous binary-compatible cast
111+
conversion can easily crash the server.)
112112
</para>
113+
</refsect1>
113114

114-
<variablelist>
115-
<title>Parameters</title>
115+
<refsect1>
116+
<title>Parameters</title>
116117

118+
<variablelist>
117119
<varlistentry>
118120
<term><replaceable>sourcetype</replaceable></term>
119121

@@ -183,6 +185,21 @@ SELECT 'The time is ' || CAST(now() AS text);
183185

184186
</refsect1>
185187

188+
<refsect1>
189+
<title>Diagnostics</title>
190+
191+
<variablelist>
192+
<varlistentry>
193+
<term><computeroutput>CREATE CAST</computeroutput></term>
194+
<listitem>
195+
<para>
196+
Message returned if the cast was successfully created.
197+
</para>
198+
</listitem>
199+
</varlistentry>
200+
</variablelist>
201+
</refsect1>
202+
186203
<refsect1 id="sql-createcast-notes">
187204
<title>Notes</title>
188205

@@ -201,8 +218,8 @@ SELECT 'The time is ' || CAST(now() AS text);
201218
argument of a different type was automatically a cast function.
202219
This convention has been abandoned in face of the introduction of
203220
schemas and to be able to represent binary compatible casts in the
204-
catalogs. (The built-in cast functions still follow this naming
205-
scheme, but they have to be shown as casts in <literal>pg_cast</>
221+
systemcatalogs. (The built-in cast functions still follow this naming
222+
scheme, but they have to be shown as casts inthe system catalog<literal>pg_cast</>
206223
now.)
207224
</para>
208225
</refsect1>
@@ -227,7 +244,7 @@ CREATE CAST (text AS int4) WITH FUNCTION int4(text);
227244

228245
<para>
229246
The <command>CREATE CAST</command> command conforms to SQL99,
230-
except that SQL99 does not make provisions for binarycompatible
247+
except that SQL99 does not make provisions for binary-compatible
231248
types. <literal>AS IMPLICIT</> is a <productname>PostgreSQL</productname>
232249
extension, too.
233250
</para>

‎doc/src/sgml/ref/create_constraint.sgml

Lines changed: 32 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<!--
2-
$Header: /cvsroot/pgsql/doc/src/sgml/ref/create_constraint.sgml,v 1.8 2002/05/18 15:44:47 petere Exp $
2+
$Header: /cvsroot/pgsql/doc/src/sgml/ref/create_constraint.sgml,v 1.9 2003/04/22 10:08:08 petere Exp $
33
PostgreSQL documentation
44
-->
55

@@ -8,30 +8,35 @@ PostgreSQL documentation
88
<refentrytitle id="sql-createconstraint-title">CREATE CONSTRAINT TRIGGER</refentrytitle>
99
<refmiscinfo>SQL - Language Statements</refmiscinfo>
1010
</refmeta>
11+
1112
<refnamediv>
12-
<refname>
13-
CREATE CONSTRAINT TRIGGER
14-
</refname>
15-
<refpurpose>
16-
define a new constraint trigger
17-
</refpurpose>
13+
<refname>CREATE CONSTRAINT TRIGGER</refname>
14+
<refpurpose>define a new constraint trigger</refpurpose>
1815
</refnamediv>
16+
1917
<refsynopsisdiv>
20-
<refsynopsisdivinfo>
21-
<date>2000-04-13</date>
22-
</refsynopsisdivinfo>
23-
<synopsis>
18+
<synopsis>
2419
CREATE CONSTRAINT TRIGGER <replaceable class="parameter">name</replaceable>
2520
AFTER <replaceable class="parameter">events</replaceable> ON
26-
<replaceable class="parameter">relation</replaceable> <replaceable class="parameter">constraint</replaceable> <replaceable class="parameter">attributes</replaceable>
27-
FOR EACH ROW EXECUTE PROCEDURE <replaceable class="parameter">func</replaceable> '(' <replaceable class="parameter">args</replaceable> ')'
28-
</synopsis>
21+
<replaceable class="parameter">table</replaceable> <replaceable class="parameter">constraint</replaceable> <replaceable class="parameter">attributes</replaceable>
22+
FOR EACH ROW EXECUTE PROCEDURE <replaceable class="parameter">func</replaceable> ( <replaceable class="parameter">args</replaceable> )
23+
</synopsis>
24+
</refsynopsisdiv>
25+
26+
<refsect1>
27+
<title>Description</title>
28+
29+
<para>
30+
<command>CREATE CONSTRAINT TRIGGER</command> is used within
31+
<command>CREATE TABLE</command>/<command>ALTER TABLE</command> and by
32+
<application>pg_dump</application> to create the special triggers for
33+
referential integrity.
34+
It is not intended for general use.
35+
</para>
36+
</refsect1>
2937

30-
<refsect2 id="R2-SQL-CREATECONSTRAINT-1">
31-
<title>
32-
Inputs
33-
</title>
34-
<para>
38+
<refsect1>
39+
<title>Parameters</title>
3540

3641
<variablelist>
3742
<varlistentry>
@@ -53,10 +58,10 @@ CREATE CONSTRAINT TRIGGER <replaceable class="parameter">name</replaceable>
5358
</varlistentry>
5459

5560
<varlistentry>
56-
<term><replaceable class="PARAMETER">relation</replaceable></term>
61+
<term><replaceable class="PARAMETER">table</replaceable></term>
5762
<listitem>
5863
<para>
59-
The name (possibly schema-qualified) of therelation in which
64+
The name (possibly schema-qualified) of thetable in which
6065
the triggering events occur.
6166
</para>
6267
</listitem>
@@ -75,7 +80,7 @@ CREATE CONSTRAINT TRIGGER <replaceable class="parameter">name</replaceable>
7580
<term><replaceable class="PARAMETER">attributes</replaceable></term>
7681
<listitem>
7782
<para>
78-
Constraint attributes.
83+
The constraint attributes.
7984
</para>
8085
</listitem>
8186
</varlistentry>
@@ -84,50 +89,26 @@ CREATE CONSTRAINT TRIGGER <replaceable class="parameter">name</replaceable>
8489
<term><replaceable class="PARAMETER">func</replaceable>(<replaceable class="PARAMETER">args</replaceable>)</term>
8590
<listitem>
8691
<para>
87-
Function to call as part of the trigger processing.
92+
The function to call as part of the trigger processing.
8893
</para>
8994
</listitem>
9095
</varlistentry>
9196
</variablelist>
92-
</para>
93-
</refsect2>
97+
</refsect1>
9498

95-
<refsect2 id="R2-SQL-CREATECONSTRAINT-2">
96-
<title>
97-
Outputs
98-
</title>
99-
<para>
99+
<refsect1>
100+
<title>Diagnostics</title>
100101

101102
<variablelist>
102103
<varlistentry>
103-
<term><computeroutput>
104-
CREATE TRIGGER
105-
</computeroutput></term>
104+
<term><computeroutput>CREATE TRIGGER</computeroutput></term>
106105
<listitem>
107106
<para>
108107
Message returned if successful.
109108
</para>
110109
</listitem>
111110
</varlistentry>
112111
</variablelist>
113-
</para>
114-
</refsect2>
115-
</refsynopsisdiv>
116-
117-
<refsect1 id="R1-SQL-CREATECONSTRAINT-1">
118-
<title>
119-
Description
120-
</title>
121-
<para>
122-
<command>CREATE CONSTRAINT TRIGGER</command> is used within
123-
<command>CREATE/ALTER TABLE</command> and by
124-
<application>pg_dump</application> to create the special triggers for
125-
referential integrity.
126-
</para>
127-
128-
<para>
129-
It is not intended for general use.
130-
</para>
131112
</refsect1>
132113
</refentry>
133114

‎doc/src/sgml/ref/create_conversion.sgml

Lines changed: 41 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<!-- $Header: /cvsroot/pgsql/doc/src/sgml/ref/create_conversion.sgml,v 1.7 2003/03/25 16:15:39 petere Exp $ -->
1+
<!-- $Header: /cvsroot/pgsql/doc/src/sgml/ref/create_conversion.sgml,v 1.8 2003/04/22 10:08:08 petere Exp $ -->
22

33
<refentry id="SQL-CREATECONVERSION">
44
<refmeta>
@@ -23,21 +23,24 @@ CREATE [DEFAULT] CONVERSION <replaceable>conversion_name</replaceable>
2323

2424
<para>
2525
<command>CREATE CONVERSION</command> defines a new encoding
26-
conversion. Conversion names may be used in theCONVERT() function
26+
conversion. Conversion names may be used in the<function>convert</function> function
2727
to specify a particular encoding conversion. Also, conversions that
28-
are marked DEFAULT can be used for automatic encoding conversion between
29-
frontend andbackend. For this purpose, two conversions, from encoding A to
30-
BAND from encoding B to A, must be defined.
28+
are marked<literal>DEFAULT</> can be used for automatic encoding conversion between
29+
client andserver. For this purpose, two conversions, from encoding A to
30+
B<emphasis>and</emphasis> from encoding B to A, must be defined.
3131
</para>
3232

3333
<para>
34-
To be able to create a conversion, you must havethe execute right
35-
on the function andthe create right on the destination schema.
34+
To be able to create a conversion, you must have<literal>EXECUTE</literal> privilege
35+
on the function and<literal>CREATE</literal> privilege on the destination schema.
3636
</para>
37+
</refsect1>
3738

38-
<variablelist>
39-
<title>Parameters</title>
4039

40+
<refsect1>
41+
<title>Parameters</title>
42+
43+
<variablelist>
4144
<varlistentry>
4245
<term><literal>DEFAULT</literal></term>
4346

@@ -75,7 +78,7 @@ CREATE [DEFAULT] CONVERSION <replaceable>conversion_name</replaceable>
7578
</varlistentry>
7679

7780
<varlistentry>
78-
<term><replaceable>source_encoding</replaceable></term>
81+
<term><replaceable>dest_encoding</replaceable></term>
7982

8083
<listitem>
8184
<para>
@@ -92,25 +95,39 @@ CREATE [DEFAULT] CONVERSION <replaceable>conversion_name</replaceable>
9295
The function used to perform the conversion. The function name may
9396
be schema-qualified. If it is not, the function will be looked
9497
up in the path.
95-
</para>
98+
</para>
9699

97-
<para>
100+
<para>
98101
The function must have the following signature:
99102

100-
<programlisting>
101-
conv_proc(
102-
INTEGER,-- source encodingid
103-
INTEGER,-- destination encodingid
104-
CSTRING,-- source string (null terminated C string)
105-
CSTRING,-- destination string (null terminated C string)
106-
INTEGER-- source string length
107-
) returns VOID;
108-
</programlisting>
103+
<programlisting>
104+
conv_proc(
105+
integer,-- source encodingID
106+
integer,-- destination encodingID
107+
cstring,-- source string (null terminated C string)
108+
cstring,-- destination string (null terminated C string)
109+
integer-- source string length
110+
) RETURNS void;
111+
</programlisting>
109112
</para>
110113
</listitem>
111114
</varlistentry>
112115
</variablelist>
116+
</refsect1>
113117

118+
<refsect1>
119+
<title>Diagnostics</title>
120+
121+
<variablelist>
122+
<varlistentry>
123+
<term><computeroutput>CREATE CONVERSION</computeroutput></term>
124+
<listitem>
125+
<para>
126+
Message returned if the conversion was successfully created.
127+
</para>
128+
</listitem>
129+
</varlistentry>
130+
</variablelist>
114131
</refsect1>
115132

116133
<refsect1 id="sql-createconversion-notes">
@@ -124,15 +141,14 @@ CREATE [DEFAULT] CONVERSION <replaceable>conversion_name</replaceable>
124141
The privileges required to create a conversion may be changed in a future
125142
release.
126143
</para>
127-
128144
</refsect1>
129145

130-
131146
<refsect1 id="sql-createconversion-examples">
132147
<title>Examples</title>
133148

134149
<para>
135-
To create a conversion from encoding UNICODE to LATIN1 using <function>myfunc</>:
150+
To create a conversion from encoding <literal>UNICODE</literal> to
151+
<literal>LATIN1</literal> using <function>myfunc</>:
136152
<programlisting>
137153
CREATE CONVERSION myconv FOR 'UNICODE' TO 'LATIN1' FROM myfunc;
138154
</programlisting>
@@ -147,7 +163,7 @@ CREATE CONVERSION myconv FOR 'UNICODE' TO 'LATIN1' FROM myfunc;
147163
<command>CREATE CONVERSION</command>
148164
is a <productname>PostgreSQL</productname> extension.
149165
There is no <command>CREATE CONVERSION</command>
150-
statement in<acronym>SQL99</acronym>.
166+
statement inthe SQL standard.
151167
</para>
152168
</refsect1>
153169

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp