Browse Source

- docs extension: explain fetch_result functionality better to prevent errors
because of wrong usage, found from Juha Heinanen


git-svn-id: https://openser.svn.sourceforge.net/svnroot/openser/trunk@5088 689a6050-402a-0410-94f2-e92a70836424

Henning Westerholt 17 years ago
parent
commit
205f28ce79
1 changed files with 9 additions and 1 deletions
  1. 9 1
      modules/db_mysql/km_dbase.c

+ 9 - 1
modules/db_mysql/km_dbase.c

@@ -251,7 +251,15 @@ int db_mysql_query(const db_con_t* _h, const db_key_t* _k, const db_op_t* _op,
 }
 }
 
 
 /**
 /**
- * Gets a partial result set.
+ * \brief Gets a partial result set, fetch rows from a result
+ *
+ * Gets a partial result set, fetch a number of rows from a database result.
+ * This function initialize the given result structure on the first run, and
+ * fetches the nrows number of rows. On subsequenting runs, it uses the
+ * existing result and fetches more rows, until it reaches the end of the
+ * result set. Because of this the result needs to be null in the first
+ * invocation of the function. If the number of wanted rows is zero, the
+ * function returns anything with a result of zero.
  * \param _h structure representing the database connection
  * \param _h structure representing the database connection
  * \param _r pointer to a structure representing the result
  * \param _r pointer to a structure representing the result
  * \param nrows number of fetched rows
  * \param nrows number of fetched rows