MySQL Optimization for Server
#1

So i am getting a "hang" when i exit the server in the server.exe
heres what kind of functions I have ongamemodeinit, that i believe are slowing me down
I aim to ask for some points in the right direction to enhance my coding, better my mysql knowledge and improve this script method im using

ALSO: is there anyway to replace for( with foreach(? ive been trying for a while now, because ive had problems without foreach with playerids etc in the past and have had to recode to foreach
pawn Code:
LoadMySQLTable()
{
    printf("===================================================================");
    printf("|+|+|+|+|+| Loading mysqltable From the MySQL Database |+|+|+|+|+|");
    printf("===================================================================");
    new rows;
    mysql_query(g_SQL, "SELECT * FROM `mysqltable` ORDER BY `id` ASC");
    if(cache_get_row_count(rows))
    {
        for(new r = 0; r < rows && r < MAX_MYSQLTABLEROWS; r++)
        {
        }
    }
    printf("%i MYSQLTABLE rows loaded from the Database!", rows);
    return 1;
}
Reply


Messages In This Thread
MySQL Optimization for Server - by SkyFlare - 31.01.2019, 04:15
Re: MySQL Optimization for Server - by SkyFlare - 31.01.2019, 05:05
Re: MySQL Optimization for Server - by Calisthenics - 31.01.2019, 07:32
Re: MySQL Optimization for Server - by SkyFlare - 31.01.2019, 10:32
Re: MySQL Optimization for Server - by Calisthenics - 31.01.2019, 11:04

Forum Jump:


Users browsing this thread: 2 Guest(s)