Converting this to threaded mysql? Getting value.
#1

Title says all. I'm trying to get the correct value but it always returns 0.

pawn Код:
MySQL_GetValue(sqlid, fieldname[], tablename[])
{
    new query[256];
    format(query, sizeof(query), "SELECT %s FROM %s WHERE id = %d LIMIT 1", fieldname, tablename, sqlid);
    mysql_tquery(dbHandle, query, "GetValue", "");
}
forward GetValue();
public GetValue()
{
    new temp[64];
    cache_get_row(0,0, temp);
    new result = strval(temp);
    return result;
}
Reply


Messages In This Thread
Converting this to threaded mysql? Getting value. - by Dokins - 10.08.2015, 23:47
Re: Converting this to threaded mysql? Getting value. - by Jefff - 11.08.2015, 00:32
Re: Converting this to threaded mysql? Getting value. - by Dokins - 11.08.2015, 00:47
Re: Converting this to threaded mysql? Getting value. - by Evocator - 11.08.2015, 09:24
Re: Converting this to threaded mysql? Getting value. - by Dokins - 11.08.2015, 20:37

Forum Jump:


Users browsing this thread: 1 Guest(s)