PDA

View Full Version : MySQL Functions?!


TheBosss
21/03/2014, 07:16 PM
Hello,

I updated my server to BlueG's mysql plugin r38,and when i compiled my gamemode i've got these errors:
error 017: undefined symbol "mysql_free_result"
error 017: undefined symbol "mysql_free_result"
error 017: undefined symbol "mysql_store_result"
error 017: undefined symbol "mysql_num_rows"
error 017: undefined symbol "mysql_store_result"
error 017: undefined symbol "mysql_num_rows"
So..can you tell me with what functions are these functions replaced?

Mattakil
21/03/2014, 07:49 PM
Is the #include below the <a_samp>?

TheBosss
21/03/2014, 07:50 PM
Yes,it is!

Mattakil
22/03/2014, 01:31 AM
show the code of the errors

DobbysGamertag
22/03/2014, 02:04 AM
mysql_free_result();
mysql_store_result();


Are depreciated in R38.

while,


mysql_num_rows();


is now:

cache_num_rows(connectionHandle = 1);


read a few pages back (from the last page) of the release topic you'll see this :)

They do since R7. You have to delete the cache manually though if you are using "cache_save" or "mysql_query".

EDIT:
Whoops, forgot that there were also uncached queries in R7. Results are cleared automatically since R21.

AceFlyer
22/03/2014, 02:20 AM
[Tutorial] Using BlueG's MySQL plugin R7 (with cache) (http://forum.sa-mp.com/showthread.php?t=337810)

this basically covers all the new additions to the plugins. since R7 the plugin supports only threaded queries.
and introduces cache.

ryansheilds
22/03/2014, 07:13 AM
If the plugin is correct I sometimes found that this was a problem with not having a few DLL files in your folder. The way I fixed it was add the following files to your root folder:

http://i.gyazo.com/14234447629692de2cc6a693fac79542.png

And ofc make sure you have libmysql.dll

If this doesn't work your either have two different versions of mysql. So download the one you need, add them and recompile the script with them.

Hope I can help