mysql multiple connections
#1

I'm trying to build a filterscript, where its database is the same user as the main gamemode, but a different databasse. Using mysql_connect again seems to be causing issues (with threaded queries).

Does anyone know how to properly allow connection to 2 or more databases at a time?
Reply
#2

Have you tried using two separate variables to store your connection in?
Reply
#3

Quote:
Originally Posted by Mionee
Посмотреть сообщение
Have you tried using two separate variables to store your connection in?
Yeah.
Reply
#4

https://sampwiki.blast.hk/wiki/MySQL/R33#mysql_option
Reply
#5

Quote:
Originally Posted by Mionee
Посмотреть сообщение
Thanks, that removed the warning, But I guess that wasn't the problem. In the filterscript, if I have the following line
pawn Код:
mysql_log(LOG_ERROR | LOG_WARNING | LOG_DEBUG);
Queries work, but the callback on mysql_tquery does not call. Commenting that line out fixes it.

EDIT: it still seems to log it with it disabled in all scripts, I guess thats good enough
Reply
#6

pawn Код:
mysql_log(LOG_ALL);
Reply
#7

Do you use MySQL R39-2, combined with the latest streamer version?

I had the same problem and it was investigated and there seems to be a conflict between both plugins, causing callbacks failing to work in filterscripts.

I fixed it by going back to MySQL plugin R34 on my server.
Reply


Forum Jump:


Users browsing this thread: 3 Guest(s)