MySQL connections - To use one or to use two connections? - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: MySQL connections - To use one or to use two connections? (
/showthread.php?tid=279988)
MySQL connections - To use one or to use two connections? -
Luka P. - 29.08.2011
I don't know is it better to use 2 connections for MySQL or just one. I mean, one for SELECT queries and one for INSERT queries. I've read somewhere that is better to use 2 connections, but I'm not sure that there is a need for that in SA-MP. What do you think?
Re: MySQL connections - To use one or to use two connections? -
MajuzzaGaming - 30.08.2011
If using database from localhost, it should be fine with just 1.
Re: MySQL connections - To use one or to use two connections? -
[HiC]TheKiller - 30.08.2011
You could use the same connections for SELECT and INSERT but you can use a separate connection for DELETE queries. DELETE queries are hardly even used, so it's not really needed.