mYSQL r7 from Blue G
#1

Hello,
My gamemode started to get a little lag because I had too many queries, so I've updated my mysql plugin to r7, and transformed everything to work as multi threaded, but now I'm facing a little problem. There are some queries that I don't want to work in other thread, and I tried something like this:
mysql_function_query(conn, "SELECT * FROM tabley ORDER BY id ASC", true, "", "");
cache_get_data(rows, fields, conn);
but when I print rows there is a huge number of rows that is not possible to be on my database.
Is this possible to do or am I doing something wrong?
I hope someone can give me a little help with this.

Thanks
Reply
#2

When use cache you'll need call a callback

mysql_function_query(conn, "SELECT * FROM tabley ORDER BY id ASC", true, "CallBack", "CallBackParametersSpecifiers", {Float,_}:...);
Reply
#3

u need to post your code
Reply
#4

Thank you, but I know how to work with the callbacks, my doubt is how to do it without the callback...
I saw in mysql r7 plugin page that this version doesn't handle non threaded queries, but the r6 handle both.
If I move back to r6, can you give me an example about how to use a threaded query and non threaded?
I just a need a little help to understand how it works, I'm not really interested in asking for any fix on my code.
Thank you guys
Reply
#5

Check out some MySQL gamemodes and see how they work, that'd probably be the best way.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)