pike.git / src / modules / Mysql / result.cmod

version» Context lines:

pike.git/src/modules/Mysql/result.cmod:549:       while ((field = mysql_fetch_field(PIKE_MYSQL_RES->result))) {    mysqlmod_parse_field(field, 0);    i++;    }    f_aggregate(i);       mysql_field_seek(PIKE_MYSQL_RES->result, 0);   }    - /*! @decl void seek(int rows) + /*! @decl void low_seek(int row)    *! -  *! Skip ahead @[rows] rows. +  *! Seek to the specified @[row].    *!    *! @note -  *! Can only seek forward. +  *! In Pike 8.0 and earlier this function was named @[seek()], but +  *! as it has a conflicting behavior vis-a-vis @[Sql.Result()->seek()], +  *! and was shadowed by a function that did use relative row addressing, +  *! it has been renamed in Pike 8.1.    *! -  +  *! @bugs +  *! This function currently does NOT update @[index]. +  *!    *! @seealso -  *! @[fetch_row()] +  *! @[fetch_row()], @[seek()]    */ - PIKEFUN void seek(int skip) + PIKEFUN void low_seek(int row)   {    if (!PIKE_MYSQL_RES->result)    Pike_error("Can't seek in uninitialized result object.\n");    -  mysql_data_seek(PIKE_MYSQL_RES->result, skip); -  +  mysql_data_seek(PIKE_MYSQL_RES->result, row);    pop_n_elems(args);   }      /*! @decl int|array(string) fetch_row()    *!    *! Fetch the next row from the result.    *!    *! Returns an array with the contents of the next row in the result.    *! Advances the row cursor to the next now.    *!