View Single Post
Old 18/06/2010, 10:05 PM   #1143
Carlton
Gangsta
 
Carlton's Avatar
 
Join Date: Mar 2010
Posts: 687
Reputation: 0
Default Re: [REL] MySQL Plugin R4 (21/04/2010)

Quote:
Originally Posted by Carlton
Err, why's mysql_retrieve_row() is returning 0?

pawn Code:
format(stringformat, sizeof(stringformat), "SELECT buSQLID FROM Buildings WHERE buName = '%s'",sscanfinput);
mysql_query(stringformat);
        mysql_store_result();
        new sid[5];
        if(mysql_retrieve_row())
        {
              mysql_fetch_field_row(sid, "buSQLID");
        }
        else {
  printf("%d", mysql_errno());
}
sscanfid[1] = strval(sid);
mysql_free_result();

MySQL_errno returns 0 also when I printed it, and this is what the MySQL log says:
Quote:
Originally Posted by MySQL log
[03:20:25] CMySQLHandler::Query(SELECT buSQLID FROM Buildings WHERE buName = 'Los Santos PD(Lower)') - Successfully executed.

[03:20:25] >> mysql_store_result( Connection handle: 1 )

[03:20:25] CMySQLHandler::StoreResult() - Result was stored.

[03:20:25] >> mysql_retrieve_row( Connection handle: 1 )

[03:20:25] >> mysql_errno( Connection handle: 1 )

[03:20:25] >> mysql_free_result( Connection handle: 1 )

[03:20:25] CMySQLHandler::FreeResult() - Result was successfully free'd.
It would be nice if I can get an answer.
Carlton is offline   Reply With Quote