Web студия "GrandView"
  Главная   Написать Контакты
   
   
О проекте
Руководство php
 

ovrimos_fetch_into

(PHP 4 >= 4.0.3, PHP 5)

ovrimos_fetch_into -- Fetches a row from the result set

Description

bool ovrimos_fetch_into ( int result_id, array &result_array [, string how [, int rownumber]] )

ovrimos_fetch_into() fetches a row from the result set into result_array, which should be passed by reference. Which row is fetched is determined by the two last parameters. how is one of Next (default), Prev, First, Last, Absolute, corresponding to forward direction from current position, backward direction from current position, forward direction from the start, backward direction from the end and absolute position from the start (essentially equivalent to 'first' but needs 'rownumber'). Case is not significant. rownumber is optional except for absolute positioning. Возвращает TRUE в случае успешного завершения или FALSE в случае возникновения ошибки.

Пример 1. A fetch into example

<?php
$conn
=ovrimos_connect("neptune", "8001", "admin", "password");
if (
$conn!=0) {
    echo
"Connection ok!";
   
$res=ovrimos_exec($conn, "select table_id, table_name from sys.tables");
    if (
$res != 0) {
        echo
"Statement ok!";
        if (
ovrimos_fetch_into($res, &$row)) {
            list(
$table_id, $table_name) = $row;
            echo
"table_id=" . $table_id . ", table_name=" . $table_name . "\n";
            if (
ovrimos_fetch_into($res, &$row)) {
                list(
$table_id, $table_name) = $row;
                echo
"table_id=" . $table_id . ", table_name=" . $table_name . "\n";
            } else {
                echo
"Next: error\n";
            }
        } else {
            echo
"First: error\n";
        }
       
ovrimos_free_result($res);
    }
   
ovrimos_close($conn);
}
?>
This example will fetch a row.



add a note add a note User Contributed Notes
ovrimos_fetch_into
There are no user contributed notes for this page.

ovrimos_fetch_row> <ovrimos_execute
Last updated: Sat, 27 Jan 2007
 
 
Новости
11 июля 2007
Сайт запущен
© 2007 info@grandviewstudio.com

Deprecated: Function set_magic_quotes_runtime() is deprecated in /home/sites/grandviewstudiocom/www/65f67d67a94ad980786580ae69e11c07/sape.php on line 324

Deprecated: Function set_magic_quotes_runtime() is deprecated in /home/sites/grandviewstudiocom/www/65f67d67a94ad980786580ae69e11c07/sape.php on line 330
Z058440144362 Z348613067571