[Plugin] [REL] MySQL Plugin (Now on github!)

The compiled version of R7-2 source can be found at the address: http://www.egaming.ro/MySQL/ or http://mirror1.egaming.ro/MySQL/
Reply

Quote:
Originally Posted by xxmitsu
Посмотреть сообщение
The compiled version of R7-2 source can be found at the address: http://www.egaming.ro/MySQL/
"Oops! ****** Chrome could not connect to www.egaming.ro"
Reply

http://www.neozftw.nl/files/mysql/r7-2/mysql.so

Is there any heads up on the GLIBCXX problem? I have been checking RPMs. I found the following package that should get GLIBCXX 3.4.9 installed: http://rpm.pbone.net/index.php3/stat...86_64.rpm.html

Perhaps that helps out. My machine appears to be running on CentOS 5, so this RPM is of no use to me.


Edit:

Actually, after some more searching, it appears that you need CentOS 6 for this plugin. CentOS 5 is incompatible: GLIBCXX 3.4.9 is not provided for CentOS 5 (3.4.8 is the most recent version).
Reply

For me with these verisons memory usage is 523 MB, with R7 (default) it was 140 - 200MB.
Reply

There is an issue with 'mysql_format' - Sometimes it doesn't display the variables but displays how they are in the format, e.g - `PoliceRank`=%d and NOT - `PoliceRank`=1.

Please refer to this thread: https://sampforum.blast.hk/showthread.php?pid=1918575#pid1918575

When I tried 'Format' it worked, so it must be an issue / bug.

Also, it sometimes displays how it should be with the correct variable numbers, and other times it shows '%d' etc.
Reply

I have a problem with saving/loading server statistics. It always null ? No errors at all, where can be the problem?

Saving:

pawn Код:
stock SaveStatistic()
{
    new szQuery[289];
    format(szQuery, 289, "UPDATE `statistika` SET `RekordoData` = '%s', `Saskaitos` = '%d', `Prisijungimai` = '%d', `Suimimai` = '%d', `Rekordas` = '%d', `DuotosBaudos` = '%d', `Ismetimai` = '%d', `Uzblokavimai` = '%d'",
    sInfo[szRecordDate], sInfo[iAccounts], sInfo[iConnects], sInfo[iArrests], sInfo[iRecord], sInfo[iFines], sInfo[iKicks], sInfo[iBans]);
    mysql_function_query(iHandle, szQuery, false, "", "");
}
Loading:

pawn Код:
#define LoadStatistic()          mysql_function_query(iHandle, "SELECT * FROM `statistika`", true, "OnServerStatisticLoad", "")
pawn Код:
PUB::OnServerStatisticLoad()
{
    new
        iFields,
        iRows;

    cache_get_data(iRows, iFields);
    if (iRows)
    {
        new szResult[12];
        cache_get_row(0, 0, sInfo[szRecordDate]);
        cache_get_row(0, 1, szResult); sInfo[iAccounts] = strval(szResult);
        cache_get_row(0, 2, szResult); sInfo[iConnects] = strval(szResult);
        cache_get_row(0, 3, szResult); sInfo[iArrests]  = strval(szResult);
        cache_get_row(0, 4, szResult); sInfo[iRecord]   = strval(szResult);
        cache_get_row(0, 5, szResult); sInfo[iFines]    = strval(szResult);
        cache_get_row(0, 6, szResult); sInfo[iKicks]    = strval(szResult);
        cache_get_row(0, 7, szResult); sInfo[iBans]     = strval(szResult);
    }
    return true;
}
PMA:

Reply

Why mysql_num_rows always return -1 ?

i have this in mysql log
Код:
[22:37:35] >> mysql_num_rows( Connection handle: 1 )
[22:37:35] CMySQLHandler::NumRows() - You cannot call this function now. (Reason: Dead Connection)
but connection is good and all other mysql functions work , only mysql_num_rows return -1 ..
Reply

Using KickPlayer in callback, which get called by mysql_function_query, shows 'Lost connection to server' for client, which should be kicked. Can anyone confirm this?
Reply

Quote:
Originally Posted by Scottas
Посмотреть сообщение
Using KickPlayer in callback, which get called by mysql_function_query, shows 'Lost connection to server' for client, which should be kicked. Can anyone confirm this?
Yeah, me, here, and pretty much everyone using R7.
Reply

fixed
Reply

I think theres another bug with the memory leak. (R7)

Every few hours or so my server goes up around 7/8mb and after it gets to 50mb+ (sometimes it may goto 60mb+) it crashes and crashdetect says it crashes to an unknown error.. which should be a plugin. Only happening since R7 and it only crashes at 50mb+
Reply

Quote:
Originally Posted by Scottas
Посмотреть сообщение
Using KickPlayer in callback, which get called by mysql_function_query, shows 'Lost connection to server' for client, which should be kicked. Can anyone confirm this?
Confirmed. Any temporary fix or whatsoever?
Reply

Guys,i was using another mysql script but i transformed it to this plugin. But there's a lot of differences between them.Others are easy,but one function is hopeless.

My plugin was StrickenKid's plug-in. There is a func. on his include,"mysql_fetch_string",i need this but there is no function for fetching string.Or i don't know

mysql_fetch_string(StrickenKid) = ?(BlueG)
Reply

Quote:

mysql_fetch_field(0,field[]);

This would be a good replacement.
Reply

I have 1 question is possible to connect to scripts into 1 db and both to work fine ?
Reply

Anyone know why my server crashes when hosted on volt-host, but is fine on home host.

It's only when I spawn...
Reply

Quote:
Originally Posted by KyleSmith
Посмотреть сообщение
Anyone know why my server crashes when hosted on volt-host, but is fine on home host.

It's only when I spawn...
Which version are you using? If you're using R7 check where you load the players information cause it happened to me, I was loading something which wasn't actually in my players database, after I added it, it stopped crashing. ( sorry if i'm wrong with this, it's only an example ).
Reply

Quote:
Originally Posted by -Luis
Посмотреть сообщение
Which version are you using? If you're using R7 check where you load the players information cause it happened to me, I was loading something which wasn't actually in my players database, after I added it, it stopped crashing. ( sorry if i'm wrong with this, it's only an example ).
doubt it as i use the same dB home hosted.
Reply

hey gay i have detect an error in the callback system , when I try to kick player in the callback I receive that :

the code :

Quote:
PHP код:
public OnCheckBanList(playerid// just a test code without verification
{
    
SendClientMessage(playeridCOLOR_ERROR"Your are banned");
    
Kick(playerid);



et tant que san andreas est ouvert les 4 phrases se repetes. And Sorry for my bad english
Reply

Dude, we can't do anything with the code you have provided. How are you calling OnCheckBanList?
Reply


Forum Jump:


Users browsing this thread: 16 Guest(s)