Jump to content
  • 0

Question

Posted

Problema intalnita (descriere): De curand incerc sa updatez sintaxele MYSQL R5 le inlocuiesc cu MYSQL R33+ dar la unele 1-2 dau erori cu MariaDB si habar nu am ce sa-i fac.
Ero(area / rile) / warning-(ul / urile):

[20:37:54] [ERROR] CMySQLQuery::Execute[()] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'WHERE `name`='Cyberoptics'' at line 1
[20:37:54] ====================================================================
[20:37:54] Error ID: 1064, Error: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'WHERE `name`='Cyberoptics'' at line 1
[20:37:54] Callback: 
[20:37:54] gQuery: UPDATE users SET `Team`='3',`Model`='3', WHERE `name`='Cyberoptics'
[20:37:54] ====================================================================


Liniile de cod / sursa / script-ul(obligatoriu):

mysql_format(SQL, gQuery, sizeof(gQuery), "UPDATE users SET `Team`='3',`Model`='3', WHERE `name`='%s'", GetName(playerid));
mysql_tquery(SQL, gQuery, "", "");


Imagini / Video (optional): - - -.
Ati incercat sa rezolvati singur?: Da. 

Ar putea sa fie o problema de la stockul GetName(playerid)?

stock GetName(playerid)
{
	new name[MAX_PLAYER_NAME];
	GetPlayerName(playerid,name,sizeof(name));
	return name;
}

De asemenea folosesc si alta variabila de preluare a numele PlayerInfo[playerid][pName]; problema ar fi de la nume?

4 answers to this question

Recommended Posts

  • 1
Posted
UPDATE users SET `Team`='3',`Model`='3'(,) WHERE `name`='%s'

Virgula din paranteze iti strica tot scriptul. Nu se pune virgula inaintea lui WHERE.

UPDATE users SET `Team`='3',`Model`='3' WHERE `name`='%s'

 

  • Upvote 1
  • 0
  • 0
Posted

xpLode cred ca raspunsul tau e corect, am scos virgula ramane doar de testat. Multumesc mult !

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.