SA-MP Forums Archive
[mysql] how logically save race times? - 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] how logically save race times? (/showthread.php?tid=536910)



[mysql] how logically save race times? - Type-R - 12.09.2014

Hey, guys this might be a stupid questions but i want your guys opinion. So do i save every single players race time into the database every time they finish the race, or do i just update what was already there for the specific race? The first option i think would be better, but wouldnt it overload the database?


Re: [mysql] how logically save race times? - Ihateyou - 12.09.2014

Do you even know basic mysql or pawn?

You need help with what? show us ur function and stuff

mysql database doesnt overload... your server is not samp-rp or ****** dont worry


Re: [mysql] how logically save race times? - Type-R - 12.09.2014

I know mysql and pawn, been in SAMP for a while. I was just asking if it would be to much if i kept putting their race time, after their each race. I am going to show it on the website, thats why i wanted to know. If it doesnt overload database, then great.


Re: [mysql] how logically save race times? - Vince - 12.09.2014

Ask the same question again when you reach a million rows in your table.


Re: [mysql] how logically save race times? - RajatPawar - 13.09.2014

Quote:
Originally Posted by Type-R
Посмотреть сообщение
I know mysql and pawn, been in SAMP for a while. I was just asking if it would be to much if i kept putting their race time, after their each race. I am going to show it on the website, thats why i wanted to know. If it doesnt overload database, then great.
Tables can hold upto even trillions of rows. It's been made for that reason - to store a large amount of data. That is why SQLite has been included into SA-MP - because a small server like this doesn't need MySQL. Also, for the reason you said, use foreign keys if possible. There's a tutorial Vince made, check it out.