Sql problem.
#1

I have the problem with sql update.

[18:54:36] [plugins/mysql] error #1054 while executing query "UPDATE `characters` SET `skin`=`295`,`score`=`11`,`fegyvereng`=`1`,`jogosi tvanyA`=`1`,`jogositvanyB`=`1`,`jogositvanyC`=`1`, `jogositvanyD`=`1`,`jogositvanyE`=`1`,`health`=`10 0.000000`,`armour`=`50.000000`,`money`=`500000`,`P osX`=`153.429108`,`PosY`=`-1952.186157`,`PosZ`=`47.875000`,`PosA`=`114.069725 `,`world`=`7269`,`interior`=`0`,`admin`=`5`,`aname `=`Memphis`,`vip`=`1`,`donator`=`1`,`jailtype`=`1` ,`jailtime`=`135`,`jailreason`=`Tesztelйs kйppen.`,`jailby`=`Cameron Marshall`,`frakcioid`=`0`,`workid`=`0`,`paydaytime `=`0`,`enablepm`=`1` WHERE `name`=`Cameron_Marshall`": Unknown column 'Cameron_Marshall' in 'where clause'
[18:54:36] [log-core] exception 0XC0000005 (ACCESS_VIOLATION) from Vectored Exception Handler catched; shutting log-core down
Reply
#2

Do you really need to update all of this information? The answer is: no, you don't. Update stuff as it changes. Write shorter queries instead of this monstrosity. How often does admin level change? Only by command, right? Then update it in the command and not anywhere else. Same goes for vip, donator, jail stuff and pretty much everything else.

As for your actual problem, learn the difference between quotes. The backtick (`) denotes an identifier (column name or table name), the normal quote (') denotes a value.
Reply
#3

You used backticks ` when you shuould have used quotes ', around every parameter
Reply
#4

Really thanks guys.
Reply
#5

One more question Vince. How often repeat the save timer on server close 100-150 player? Of course not to become lag server because save timer.
Reply
#6

If you update stuff as it changes then you don't need a "save timer" at all.
Reply
#7

Yeah but what about player coordinates? Save player coords when player disconnect, its alright. But what happened when server is timed out? OnPlayerDisconnect it does not run. I do not want to put update stuff to OnPlayerUpdate. Or I trust that it will not timed out the server?
Reply
#8

Your server shouldn't crash frequently enough for that to be a problem... if it is, there's something seriously wrong. If your server / a player crashes, he will return to the last saved position.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)