AW: [REL] MySQL Plugin (****** Project) -
maddinat0r - 29.06.2013
Ah sorry, forgot that.
http://dfiles.eu/files/xgosttogj
Re: [REL] MySQL Plugin (****** Project) -
GiamPy. - 29.06.2013
It doesn't seem to give me any dump file.
Re: [REL] MySQL Plugin (****** Project) -
maddinat0r - 29.06.2013
Does it even crash? Also try to run everything as administrator.
Re: [REL] MySQL Plugin (****** Project) -
GiamPy. - 30.06.2013
Quote:
Originally Posted by Pain123
Does it even crash? Also try to run everything as administrator.
|
It does crash.
As for running as administrator, I tried but there's no sign of the dump file.
Re: [REL] MySQL Plugin (****** Project) -
kurta999 - 02.07.2013
This is what?
[00:08:40] [ERROR] CMySQLHandler::Connect() - Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2) (error ID: 2002).
AW: Re: [REL] MySQL Plugin (****** Project) -
maddinat0r - 02.07.2013
Quote:
Originally Posted by dusk
Okay. So I just downloaded R26 plugin and include. And i get these errors:
pawn Code:
GRPLT.pwn(299) : error 017: undefined symbol "mysql_log" GRPLT.pwn(10786) : error 017: undefined symbol "cache_insert_id" GRPLT.pwn(19950) : error 017: undefined symbol "cache_insert_id"
I mean, i read the goddamn include, i know that they are there! So what the..? Any ideas? :/
|
Maybe you included an older MySQL include before including the new one?
Quote:
Originally Posted by kurta999
This is what?
[00:08:40] [ERROR] CMySQLHandler::Connect() - Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2) (error ID: 2002).
|
What MySQL server version are you using (5.1, 5.5)?
Re: AW: Re: [REL] MySQL Plugin (****** Project) -
dusk - 02.07.2013
No.. I am sure that i only have 1 include in my folders. And only 1 #include line.
Re: [REL] MySQL Plugin (****** Project) -
kurta999 - 02.07.2013
I don't know currently which version is on the host, but this is not imporant.
The big problem is the cache_get_row_int() or I think float and etc doesn't support "enum" data types.
Some rows in my DB looks like this, example: "level enum('0', '1', '2', '3', '4')" and value: '4'.
If i want to get this value, then then this will be in the debug:
Code:
[20:49:40] [DEBUG] CMySQLResult::GetRowData - row: '0', field: '7', data: "4"
[20:49:40] [ERROR] cache_get_row_int - invalid data type
[20:49:40] [DEBUG] cache_get_row_int - connection handle: 1
This is good, any older version doesn't have any problem with this. Please fix this, thanks!
And would be very good to add MySQL query to the debug, if LOG_DEBUG is enabled, because now very hard to find where the problem.
AW: [REL] MySQL Plugin (****** Project) -
maddinat0r - 03.07.2013
It depends on the size of the fetched data. If you have long strings and many fields in the cache, it will consume more memory than having lesser fields and smaller strings.
Re: [REL] MySQL Plugin (****** Project) -
cyber_punk - 05.07.2013
I seem to be having a server crash from R26 any chance I can get the .pdb file so I know what functions are causing it (not sure why it was stopped from being included in the download file). Its a great asset.
AW: [REL] MySQL Plugin (****** Project) -
maddinat0r - 05.07.2013
You mean that crash when closing the server? That is already fixed.
And I'll include the .pdb file in the download. I save every .pdb file for every revision, if you really need it I can upload it for you.
Re: [REL] MySQL Plugin (****** Project) -
Calabresi - 05.07.2013
I found a bug.
mysql_format() causes the server to crash if the input is too long, on Linux. I don't know the exact character count but seems like mysql_format() is not able to handle long strings. I have been using format() instead of it and everything works perfect.
I think you gotta fix it ASAP, as its a very important function for this plugin. As a reminder again, that only happens in Linux.
Re: AW: [REL] MySQL Plugin (****** Project) -
cyber_punk - 05.07.2013
Quote:
Originally Posted by Pain123
You mean that crash when closing the server? That is already fixed.
And I'll include the .pdb file in the download. I save every .pdb file for every revision, if you really need it I can upload it for you.
|
No this happens from some other reason. I have no error in the mysql log so it doesn't seem to be related to a query. It seems almost random. If you have it I would appreciate an upload so I can report what function is the cause.
AW: Re: AW: [REL] MySQL Plugin (****** Project) -
maddinat0r - 07.07.2013
Quote:
Originally Posted by Calabresi
I found a bug.
mysql_format() causes the server to crash if the input is too long, on Linux. I don't know the exact character count but seems like mysql_format() is not able to handle long strings. I have been using format() instead of it and everything works perfect.
I think you gotta fix it ASAP, as its a very important function for this plugin. As a reminder again, that only happens in Linux.
|
I couldn't reproduce it with a 400 characters long string in R27, so I assume I've fixed this bug while rewriting mysql_format.
Quote:
Originally Posted by cyber_punk
No this happens from some other reason. I have no error in the mysql log so it doesn't seem to be related to a query. It seems almost random. If you have it I would appreciate an upload so I can report what function is the cause.
|
Sorry that you had to wait so long, hadn't much time these days.
http://dfiles.eu/files/45pzfxmjf
Here is the complete package with the .pdb file.
EDIT:
R27 is released.
Changes:
- added support for y_inline
- fixed some memory leaks
- improved Windows XP compatibility
- fixed bug where OnQueryError parameters had empty values
- renamed mysql_real_escape_string to mysql_escape_string
- rewrote native mysql_format
- reduced usage of memory allocation (malloc)
- added enum datatype support to int-conversion natives
- replaced mysql_function_query native wrapper with pawn define
- changed MySQL connector again (sorry for that, Windows users will have to update the libmysql.dll again)
- improved HTML log file design
mysql_format now also supports precision and width for the %f and %d specifier just like the normal format native.
An example:
Code:
mysql_format(SQLHandle, Query, sizeof(Query), "SELECT * FROM foo WHERE bar = '%04d'", 4);
printf("Query1: %s", Query);
mysql_format(SQLHandle, Query, sizeof(Query), "UPDATE foo SET PosX = '%.2f', PosY = '%06.4f'", 123.4567, 987.654);
printf("Query2: %s", Query);
Output:
Quote:
Query1: SELECT * FROM foo WHERE bar = '0004'
Query2: UPDATE foo SET PosX = '123.45', PosY = '000987.6540'
|
Another small change to mysql_format is the difference between the specifier '%x' and '%X', where '%x' will give a hex-decimal value in lowercase (like '12beaf') and '%X' in uppercase ('12BEAF').
Re: [REL] MySQL Plugin (****** Project) -
cyber_punk - 07.07.2013
Thanks, I just tried R27 I updated the connector, plugin and include file. Recompile my script. The server crashes on the first query passed which is a create table if not exists. This worked in the previous versions just fine.
AW: [REL] MySQL Plugin (****** Project) -
maddinat0r - 07.07.2013
Could you give me some more informations, like some debug messages out of the mysql_log or maybe even a dump-file?
Re: [REL] MySQL Plugin (****** Project) -
cyber_punk - 07.07.2013
The only thing in the log is the query being passed, that it was passed successfully, and then calling the callback. However the server crashes after that. Post what I need for a dump file and I will provide one no problem.
AW: [REL] MySQL Plugin (****** Project) -
maddinat0r - 07.07.2013
http://www.solidfiles.com/d/2bebfcd366/
Download this package, extract it to your server root directory (where the samp-server.exe is). Then edit the file paths in the start.bat file. Execute this bat file and you should get a .dmp file when the server crashes. Send me this file
via PM.
Re: [REL] MySQL Plugin (****** Project) -
Scenario - 12.07.2013
Do you have R27? If so, then check the a_mysql include for the function name. I think I'm still on the BETA function names.
AW: [REL] MySQL Plugin (****** Project) -
maddinat0r - 12.07.2013
No, it is mysql_tquery_inline, you just forgot to add "#define MYSQL_USE_YINLINE" before including a_mysql.inc.