Entries in the tables
#1

Hello there

Here I have a system object that you can ask / take down.

I use a table in this form:
variable [id] [nombre_maximum]

For security and other uses I record everything in MySQL, and the table entry I use a function.

The only trouble with this function is qu'admettons I 500 maximum, and I have a object id 1 and id 500 it does not use the unused inputs.

How do I change my function to use unused inputs?

Here's the function:

pawn Код:
stock IDExistantObjet()
{
    new requete[1024], result[1024];
   
    format(requete, sizeof(requete), "SELECT COUNT(*) FROM srp_players_objets");
    mysql_query(requete);
   
    mysql_store_result();
   
    mysql_fetch_row(result);
   
    new objvar = strval(result) + 1;
   
    mysql_free_result();
   
    return objvar;
}
thx
Reply


Messages In This Thread
Entries in the tables - by Baltimore - 23.07.2014, 13:04
Re: Entries in the tables - by Baltimore - 23.07.2014, 17:52
Re: Entries in the tables - by Virtual1ty - 23.07.2014, 18:09
Re: Entries in the tables - by Baltimore - 23.07.2014, 18:21
Re: Entries in the tables - by Baltimore - 24.07.2014, 00:06
Re: Entries in the tables - by Baltimore - 24.07.2014, 11:48
Re: Entries in the tables - by Baltimore - 25.07.2014, 11:32

Forum Jump:


Users browsing this thread: 1 Guest(s)