SA-MP Forums Archive
Files or MySQL - 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: Files or MySQL (/showthread.php?tid=562100)



Files or MySQL - Sime30 - 06.02.2015

Hi guys!

QUESTION

If you have to choose between saving your logs(new users,chat,bans etc..) to your scriptfiles or to your MySQL database, what would you choose? And why?

All answers are appreciated!!!


Regards!


Re: Files or MySQL - Luis- - 06.02.2015

MySQL 100%.


Re: Files or MySQL - Vince - 06.02.2015

Both. System logs to file, all other logs (player actions and whatnot) to the database. That way if the database can't be contacted all the relevant things are logged to file.


Re: Files or MySQL - EnforcerDon - 07.02.2015

Both. I use files for logs and server data and SQL for saving dynamic data, eg users, vehicles and bans.

Why? Logs are good for just recording data that probably will never need to be seen again, like the chatlog. SQL is good for storing dynamic data that needs to be read from and updated regularly, hence its use for userdata and other dynamic systems. Also SQL can be used on your website as well, for example players could log in to your website using their in game username, because the website would have access to the same database as the game server.


Re: Files or MySQL - Sime30 - 07.02.2015

Nice!

Anybody else wanna answer?


Re: Files or MySQL - CalvinC - 07.02.2015

I haven't tried saving logs in a MySQL database, so dunno how that would work.
But i would definitely save stats in MySQL, it's way more organised than having hundreds of different files.


Re: Files or MySQL - Sime30 - 07.02.2015

Your answer, ******, is very, how should I say, inspiring.

If you read between the lines, you can surely see that you want from me to create something unique, something that isn't already done. We are all tired of seeing same stuff over and over again. If we think, plan and create by our head and hands, we wouldn't need others help. Thank you , Alex(Is it Alex?), for reminding me that!