StrickenKid's MYSQL Issue
#4

After executing your SELECT query and storing the result, you need to do a check to see if there were any results, which can be done as follows:
pawn Код:
mysql_query(yourquerystring);
mysql_store_result();

if(mysql_num_rows())
{
    // wahey, resultttt! fetch field(s) now or w/e!
}else{
    // no results found :-(
}
I believe trying to fetch a field of nil result is the reason for your mysql crash.
Reply


Messages In This Thread
StrickenKid's MYSQL Issue - by SkyWinder - 26.07.2012, 19:22
Re: StrickenKid's MYSQL Issue - by Benjo - 26.07.2012, 20:53
Re: StrickenKid's MYSQL Issue - by SkyWinder - 27.07.2012, 15:58
Re: StrickenKid's MYSQL Issue - by Benjo - 27.07.2012, 16:30
Re: StrickenKid's MYSQL Issue - by SkyWinder - 27.07.2012, 16:39

Forum Jump:


Users browsing this thread: 2 Guest(s)