How to speed up queries
#1

Hi,

I'am using latest mysql BlueG plugin. Everything okey, but i need to send a lot of queries, save info in houses, bussines, player info, show a lot of things from database. When is more players and there is more connecting, disconnecting, need more queries and sometimes, there is too many queries not finished and players don't see login screens and so on, where i use queries. I know that i need to use less queries, but if you have big server with a lot of things it'is hard to do, maybe a little, but still a lot of players do a lot of queries. Maybe there is way without doing something with queries just speed up them?
Reply
#2

Queries finish when they're done, if you are using threaded queries then execute your "login" or whatever stuff in that "callback", SQL queries can be sped up by using the right techniques (updating only on different values) and such.
Reply
#3

Main HINT.

NEVER USE * , Only SELECT the required fields. This reduce the query time.
And Make your query more clear by using LIMIT function.
Reply
#4

I use * when player connect because i need select everything just there. LIMIT i use everywhere.
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)