pg_result_seek(3) php man page | unix.com

Man Page: pg_result_seek

Operating Environment: php

Section: 3

PG_RESULT_SEEK(3)														 PG_RESULT_SEEK(3)

pg_result_seek - Set internal row offset in result resource

SYNOPSIS
bool pg_result_seek (resource $result, int $offset)
DESCRIPTION
pg_result_seek(3) sets the internal row offset in a result resource.
PARAMETERS
o $result - PostgreSQL query result resource, returned by pg_query(3), pg_query_params(3) or pg_execute(3) (among others). o $offset - Row to move the internal offset to in the $result resource. Rows are numbered starting from zero.
RETURN VALUES
Returns TRUE on success or FALSE on failure.
EXAMPLES
Example #1 pg_result_seek(3) example <?php // Connect to the database $conn = pg_pconnect("dbname=publisher"); // Execute a query $result = pg_query($conn, "SELECT author, email FROM authors"); // Seek to the 3rd row (assuming there are 3 rows) pg_result_seek($result, 2); // Fetch the 3rd row $row = pg_fetch_row($result); ?>
SEE ALSO
pg_fetch_row(3), pg_fetch_assoc(3), pg_fetch_array(3), pg_fetch_object(3), pg_fetch_result(3). PHP Documentation Group PG_RESULT_SEEK(3)
Related Man Pages
pg_fetch_result(3) - php
pg_fetch_all(3) - php
pg_fetch_assoc(3) - php
pg_field_is_null(3) - php
pg_num_rows(3) - php
Similar Topics in the Unix Linux Community
Merging of rows
To find the Row number
Updated files information
Read values in each col starting 3rd row.Print occurrence value.
Analyzing last 2 fields of 1 row and 3rd field of next row