SQL LoadBiz doens't works
#3

Quote:
Originally Posted by Sk1lleD
Посмотреть сообщение
The server will crash immediately on load
Are you really sure that the field is not null? Because if it is, it causes crashes.

By the way, you can just do:
pawn Код:
db_get_field_assoc(Result,"owner",BizInfo[a][bOwner],30);
Quote:
Originally Posted by TH3_R3D™
Посмотреть сообщение
but try:

pawn Код:
public LoadBiz()
{
    new query[2048], DBResult: Result;
    Result = db_query(Database,"SELECT * FROM `bizs`");
    if(db_num_rows(Result))
    {
        db_get_field_assoc(Result,"owner",query,sizeof(query));
        format(BizInfo[a][bOwner], 30, query);
//other code here
}
}
He does not have only 1 row, so he should use a loop.

@Sk1lleD Don't forget to use "db_next_row".
Reply


Messages In This Thread
SQL LoadBiz doens't works - by Sk1lleD - 26.07.2013, 18:10
Re: SQL LoadBiz doens't works - by TH3_R3D™ - 26.07.2013, 19:36
Re: SQL LoadBiz doens't works - by Konstantinos - 26.07.2013, 19:43
Re: SQL LoadBiz doens't works - by Sk1lleD - 26.07.2013, 20:36

Forum Jump:


Users browsing this thread: 1 Guest(s)