MOVE <refpurpose>position a cursor</refpurpose> — カーソルの位置を決める
MOVE [direction] [ FROM | IN ]cursor_name<phrase>where <replaceable class="parameter">direction</replaceable> can be one of:</phrase> ここでdirectionは以下の一つです。 NEXT PRIOR FIRST LAST ABSOLUTEcountRELATIVEcountcountALL FORWARD FORWARDcountFORWARD ALL BACKWARD BACKWARDcountBACKWARD ALL
<command>MOVE</command> repositions a cursor without retrieving any data.
<command>MOVE</command> works exactly like the <command>FETCH</command>
command, except it only positions the cursor and does not return rows.
MOVEはデータを取り出すことなくカーソルの位置を変更します。
MOVEはFETCHコマンドとまったく同じように動作しますが、カーソルの位置を変えるだけで行を返しません。
The parameters for the <command>MOVE</command> command are identical to
those of the <command>FETCH</command> command; refer to
<xref linkend="sql-fetch"/>
for details on syntax and usage.
MOVEコマンドのパラメータはFETCHコマンドと同一です。
構文と使用方法についての詳細はFETCHを参照してください。
On successful completion, a <command>MOVE</command> command returns a command
tag of the form
正常に終了すると、MOVEは以下の形式のコマンドタグを返します。
MOVE count
The <replaceable class="parameter">count</replaceable> is the number
of rows that a <command>FETCH</command> command with the same parameters
would have returned (possibly zero).
countは同じパラメータを与えたFETCHコマンドが返すはずの行数です
(この値は0の場合もあります)。
BEGIN WORK; DECLARE liahona CURSOR FOR SELECT * FROM films; -- Skip the first 5 rows: -- 最初の5行をスキップします。 MOVE FORWARD 5 IN liahona; MOVE 5 -- Fetch the 6th row from the cursor liahona: -- liahonaカーソル内の6行目を抽出します。 FETCH 1 FROM liahona; code | title | did | date_prod | kind | len -------+--------+-----+------------+--------+------- P_303 | 48 Hrs | 103 | 1982-10-22 | Action | 01:37 (1 row) -- Close the cursor liahona and end the transaction: -- カーソルliahonaを閉じ、トランザクションを終了します。 CLOSE liahona; COMMIT WORK;
There is no <command>MOVE</command> statement in the SQL standard.
標準SQLにはMOVE文はありません。