Skip to content

Commit 177179b

Browse files
committed
合并sizhitu翻译的fetch.sgml和runtime.sgml并review fix
1 parent ac20f9b commit 177179b

File tree

2 files changed

+725
-542
lines changed

2 files changed

+725
-542
lines changed

postgresql/doc/src/sgml/ref/fetch.sgml

Lines changed: 23 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ doc/src/sgml/ref/fetch.sgml
33
PostgreSQL documentation
44
-->
55

6-
<refentry id="SQL-FETCH">
6+
<refentry id="sql-fetch">
77

88
<!--==========================orignal english content==========================
99
<indexterm zone="sql-fetch">
@@ -112,14 +112,14 @@ ____________________________________________________________________________-->
112112
<!--==========================orignal english content==========================
113113
<para>
114114
A cursor has an associated position, which is used by
115-
<command>FETCH</>. The cursor position can be before the first row of the
115+
<command>FETCH</command>. The cursor position can be before the first row of the
116116
query result, on any particular row of the result, or after the last row
117117
of the result. When created, a cursor is positioned before the first row.
118118
After fetching some rows, the cursor is positioned on the row most recently
119-
retrieved. If <command>FETCH</> runs off the end of the available rows
119+
retrieved. If <command>FETCH</command> runs off the end of the available rows
120120
then the cursor is left positioned after the last row, or before the first
121-
row if fetching backward. <command>FETCH ALL</> or <command>FETCH BACKWARD
122-
ALL</> will always leave the cursor positioned after the last row or before
121+
row if fetching backward. <command>FETCH ALL</command> or <command>FETCH BACKWARD
122+
ALL</command> will always leave the cursor positioned after the last row or before
123123
the first row.
124124
</para>
125125
____________________________________________________________________________-->
@@ -136,8 +136,8 @@ ____________________________________________________________________________-->
136136

137137
<!--==========================orignal english content==========================
138138
<para>
139-
The forms <literal>NEXT</>, <literal>PRIOR</>, <literal>FIRST</>,
140-
<literal>LAST</>, <literal>ABSOLUTE</>, <literal>RELATIVE</> fetch
139+
The forms <literal>NEXT</literal>, <literal>PRIOR</literal>, <literal>FIRST</literal>,
140+
<literal>LAST</literal>, <literal>ABSOLUTE</literal>, <literal>RELATIVE</literal> fetch
141141
a single row after moving the cursor appropriately. If there is no
142142
such row, an empty result is returned, and the cursor is left
143143
positioned before the first row or after the last row as
@@ -153,7 +153,7 @@ ____________________________________________________________________________-->
153153

154154
<!--==========================orignal english content==========================
155155
<para>
156-
The forms using <literal>FORWARD</> and <literal>BACKWARD</>
156+
The forms using <literal>FORWARD</literal> and <literal>BACKWARD</literal>
157157
retrieve the indicated number of rows moving in the forward or
158158
backward direction, leaving the cursor positioned on the
159159
last-returned row (or after/before all rows, if the <replaceable
@@ -171,8 +171,8 @@ ____________________________________________________________________________-->
171171

172172
<!--==========================orignal english content==========================
173173
<para>
174-
<literal>RELATIVE 0</>, <literal>FORWARD 0</>, and
175-
<literal>BACKWARD 0</> all request fetching the current row without
174+
<literal>RELATIVE 0</literal>, <literal>FORWARD 0</literal>, and
175+
<literal>BACKWARD 0</literal> all request fetching the current row without
176176
moving the cursor, that is, re-fetching the most recently fetched
177177
row. This will succeed unless the cursor is positioned before the
178178
first row or after the last row; in which case, no row is returned.
@@ -189,15 +189,15 @@ ____________________________________________________________________________-->
189189
<!--==========================orignal english content==========================
190190
<para>
191191
This page describes usage of cursors at the SQL command level.
192-
If you are trying to use cursors inside a <application>PL/pgSQL</>
192+
If you are trying to use cursors inside a <application>PL/pgSQL</application>
193193
function, the rules are different &mdash;
194-
see <xref linkend="plpgsql-cursors">.
194+
see <xref linkend="plpgsql-cursor-using"/>.
195195
</para>
196196
____________________________________________________________________________-->
197197
<para>
198198
这个页面描述在 SQL 命令层面上对游标的使用。如果想要在
199199
<application>PL/pgSQL</application>函数中使用游标,规则会有所不同
200-
&mdash; 请见<xref linkend="plpgsql-cursors"/>。
200+
&mdash; 请见<xref linkend="plpgsql-cursor-using"/>。
201201
</para>
202202
</note>
203203
</refsect1>
@@ -535,10 +535,10 @@ ____________________________________________________________________________-->
535535
<!--==========================orignal english content==========================
536536
<para><replaceable class="parameter">count</replaceable> is a
537537
possibly-signed integer constant, determining the location or
538-
number of rows to fetch. For <literal>FORWARD</> and
539-
<literal>BACKWARD</> cases, specifying a negative <replaceable
538+
number of rows to fetch. For <literal>FORWARD</literal> and
539+
<literal>BACKWARD</literal> cases, specifying a negative <replaceable
540540
class="parameter">count</replaceable> is equivalent to changing
541-
the sense of <literal>FORWARD</> and <literal>BACKWARD</>.
541+
the sense of <literal>FORWARD</literal> and <literal>BACKWARD</literal>.
542542
</para>
543543
____________________________________________________________________________-->
544544
<para><replaceable class="parameter">count</replaceable>
@@ -578,7 +578,7 @@ ____________________________________________________________________________-->
578578

579579
<!--==========================orignal english content==========================
580580
<para>
581-
On successful completion, a <command>FETCH</> command returns a command
581+
On successful completion, a <command>FETCH</command> command returns a command
582582
tag of the form
583583
<screen>
584584
FETCH <replaceable class="parameter">count</replaceable>
@@ -610,8 +610,8 @@ ____________________________________________________________________________-->
610610
<!--==========================orignal english content==========================
611611
<para>
612612
The cursor should be declared with the <literal>SCROLL</literal>
613-
option if one intends to use any variants of <command>FETCH</>
614-
other than <command>FETCH NEXT</> or <command>FETCH FORWARD</> with
613+
option if one intends to use any variants of <command>FETCH</command>
614+
other than <command>FETCH NEXT</command> or <command>FETCH FORWARD</command> with
615615
a positive count. For simple queries
616616
<productname>PostgreSQL</productname> will allow backwards fetch
617617
from cursors not declared with <literal>SCROLL</literal>, but this
@@ -648,9 +648,9 @@ ____________________________________________________________________________-->
648648

649649
<!--==========================orignal english content==========================
650650
<para>
651-
<xref linkend="sql-declare">
651+
<xref linkend="sql-declare"/>
652652
is used to define a cursor. Use
653-
<xref linkend="sql-move">
653+
<xref linkend="sql-move"/>
654654
to change cursor position without retrieving data.
655655
</para>
656656
____________________________________________________________________________-->
@@ -775,8 +775,8 @@ ____________________________________________________________________________-->
775775

776776
<!--==========================orignal english content==========================
777777
<para>
778-
The SQL standard allows only <literal>FROM</> preceding the cursor
779-
name; the option to use <literal>IN</>, or to leave them out altogether, is
778+
The SQL standard allows only <literal>FROM</literal> preceding the cursor
779+
name; the option to use <literal>IN</literal>, or to leave them out altogether, is
780780
an extension.
781781
</para>
782782
____________________________________________________________________________-->

0 commit comments

Comments
 (0)