[GameMode] Basic SQLite - 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: Gamemode Scripts (
https://sampforum.blast.hk/forumdisplay.php?fid=71)
+--- Thread: [GameMode] Basic SQLite (
/showthread.php?tid=384578)
Re: Basic SQLite -
CrazyChoco - 01.02.2013
SQLite is the fatest, but MySQL is best
Quote:
This forum requires that you wait 120 seconds between posts. Please try again in 85 seconds.
|
-.-"
Re: Basic SQLite -
Alvon - 03.02.2013
Interesting technique. I greatly appreciate it. Whatever it is. Congratulations on your efforts.
Note - MySQL is the best of the best and convenient to use.
#March
Re: Basic SQLite -
[TC]XxJuggaloxX - 10.02.2013
How exactly are you supposed to save stats?
I assume it's something to do with this
UPDATE `USERS` SET (etc. etc. etc.)
However, I am not 100% sure how. Right now I am using INI and I hate it, Causes so many issues. I used MySQL in the past however, I found myself without a Database now, and am trying alternative means. This so far has worked out, up until the saving the stats part that is.
Can you provide a small example of how to do so based on your works you have so far?
Re: Basic SQLite -
ViruZz - 11.02.2013
Quote:
Originally Posted by [TC]XxJuggaloxX
How exactly are you supposed to save stats?
I assume it's something to do with this
UPDATE `USERS` SET (etc. etc. etc.)
However, I am not 100% sure how. Right now I am using INI and I hate it, Causes so many issues. I used MySQL in the past however, I found myself without a Database now, and am trying alternative means. This so far has worked out, up until the saving the stats part that is.
Can you provide a small example of how to do so based on your works you have so far?
|
For example, you're trying to save the players admin level, you will go like this.
pawn Code:
format(string, sizeof(string), "UPDATE `USERS` SET `ADMINLEVEL`='%i' WHERE `NAME`='%s'", PlayerInfo[playerid][pAdminLevel], DB_Escape(GetPlayerNameEx(playerid)));
db_free_result(db_query(UserDatabase, string));
Re: Basic SQLite -
ReneG - 12.02.2013
db_free_result is redundant you know....since UPDATE doesn't return any data.
Re: Basic SQLite -
ViruZz - 12.02.2013
Quote:
Originally Posted by VincentDunn
db_free_result is redundant you know....since UPDATE doesn't return any data.
|
I just copied it from my LVRP Script since he wanted a piece of code that I'm currently using
Re: Basic SQLite -
ReneG - 12.02.2013
Quote:
Originally Posted by ViruZz
I just copied it from my LVRP Script since he wanted a piece of code that I'm currently using
|
Still doesn't justify you freeing an empty result set. It's like trying to empty a bucket that's already empty.