PDA

View Full Version : Problem in my houses system


Sphex
05/05/2012, 06:21 AM
nvm, succeeded.

Crazymax
05/05/2012, 06:30 AM
lol what are you doing... why so many formats when you can just do it on one line?

just do some like.. (not tested)


new str[256];
format(query, sizeof(query), "SELECT `owned`,`ownername`,`sellprice` FROM `houses` WHERE `hosueid` = '%d'", x);
mysql_query(query);
mysql_store_result();
if(mysql_num_rows()!=0)
{
if(mysql_fetch_row_format(str))
{
sscanf(str, "p<|>dsd",hInfo[x][howned],hInfo[x][hownername],hInfo[x][hsellprice]);
}
}
mysql_free_result();

Sphex
05/05/2012, 07:26 AM
nvm, succeeded.