Add function fetch_row for pg_fetch_row
This commit is contained in:
parent
8520059ec2
commit
fdfbbcb3d3
1 changed files with 11 additions and 1 deletions
|
|
@ -115,7 +115,8 @@ class Database
|
|||
* \brief send a sql string to the database
|
||||
* \param $p_string sql string
|
||||
* \param $p_array array for the SQL string (see pg_query_params)
|
||||
* \return false if error otherwise true
|
||||
* \return the result of the query, a resource or false if an
|
||||
* error occured
|
||||
*/
|
||||
function exec_sql( $p_string,$p_array=null)
|
||||
{
|
||||
|
|
@ -737,6 +738,15 @@ class Database
|
|||
{
|
||||
return pg_fetch_result($ret,$p_row,$p_col);
|
||||
}
|
||||
/*!\brief wrapper for the function pg_fetch_row
|
||||
*\param $ret is the result of pg_exec (exec_sql)
|
||||
*\param $p_row is the indice of the row
|
||||
*\return an array indexed from 0
|
||||
*/
|
||||
static function fetch_row($ret,$p_row)
|
||||
{
|
||||
return pg_fetch_row($ret,$p_row);
|
||||
}
|
||||
|
||||
/*!\brief wrapper for the function pg_lo_unlink
|
||||
*\param $p_oid is the of oid
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue