09.01.2017, 22:08
Hi. for some reason SQLite takes a long time to perform queries. it's random, ranges from 20-2000 ms.
The thing is everything else on the server is responsive and fast, its as if SQL is slacking behind, even though it gets the job done.
Any ideas?
Edit: apparently its just one, benchmarked alot of them and they were fine, besides the one that backup all the playerstats.
Here is the query format:
The thing is everything else on the server is responsive and fast, its as if SQL is slacking behind, even though it gets the job done.
Any ideas?
Edit: apparently its just one, benchmarked alot of them and they were fine, besides the one that backup all the playerstats.
Here is the query format:
Код:
format(Query,sizeof(Query),"UPDATE `USERS` SET ALEVEL = %i, KILLS = %i, DEATHS = %i, HSPREE = %i, TIMEP = '%s', MAINSET = '%s', PTOKEN = %i, PMONEY = %i, PlayerLevel = %i, PlayerLevelExp = %i, TotalExp = %i WHERE `UserID` = %i COLLATE NOCASE", PlayerInfo[playerid][aLevel], PlayerInfo[playerid][Kills], PlayerInfo[playerid][Deaths], PlayerInfo[playerid][hSpree], DB_Escape(timeString), DB_Escape(cfgString), PlayerInfo[playerid][pTokens], PlayerInfo[playerid][pMoney], PlayerExp[playerid][0], PlayerExp[playerid][1], PlayerExp[playerid][2], PlayerInfo[playerid][UserID]);