MySQL Problem
#6

Quote:
Originally Posted by BlackBank3
Посмотреть сообщение
This is weird, because i did a test on my Saving script and my saving time was 14ms with the R6 plugin.
My SaveAccount code:
http://pastebin.com/0xBwtiG1

Is your MySQL database on the same SA:MP server (localhost)?
That is because your code uses the primary key which is indexed. Pawno' uses the playername which is not indexed (I assume) and thus takes more time to look up. If you were to index on a TEXT field it would take even longer.

What I have done in my code is save the userid to a variable since I fetch the rest of the account as well. This method is probably the same as yours and is faster.
Reply


Messages In This Thread
MySQL Problem - by 'Pawno. - 18.09.2012, 10:43
Re: MySQL Problem - by mamorunl - 18.09.2012, 10:53
Re: MySQL Problem - by playbox12 - 18.09.2012, 10:56
Re: MySQL Problem - by BlackBank - 18.09.2012, 12:53
AW: MySQL Problem - by 'Pawno. - 18.09.2012, 13:01
Re: MySQL Problem - by mamorunl - 18.09.2012, 13:26

Forum Jump:


Users browsing this thread: 3 Guest(s)