mysql error 1064
#1

I have MySQL error #1064

Quote:

[09:34:12] [ERROR] CMySQLQuery::Execute[()] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1

Code:
https://pastebin.com/Y3UcDWax

Can someone help?
Reply
#2

pawn Код:
public OnPlayerConnect(playerid)
{
    new vardas [MAX_PLAYER_NAME], query[64];
    GetPlayerName(playerid, vardas, sizeof(vardas));
    format(query, sizeof(query), "SELECT `id` FROM `user` WHERE `vardas` = '%s'", vardas);
    mysql_function_query(manomysql, query, true, "OnUserCheck", "i", playerid);
    return 1;
}
Reply
#3

Now it is another error
[10:34:03] [ERROR] CMySQLQuery::Execute[()] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''pass' at line 1

"pass' is part of my register password.When I registering, I create passoword (password) and where is something wrong
Reply
#4

We're in 2018 but telepathy hasn't been invented yet. You need to show us the code.
Reply
#5

My Code is in first post pastebin

now updated:
https://pastebin.com/rmBSbKpc
Reply
#6

pawn Код:
format(query, sizeof(query), "INSERT INTO `user` (`vardas`, `slaptazodis`) VALUES ('%s', '%s')", vardas, inputtext);
Next time just show the code which gives you the error, not the whole gamemode...
Reply
#7

error
Quote:

[10:57:16] [ERROR] CMySQLQuery::Execute[()] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1

code: https://pastebin.com/eZfh0dRE
Reply
#8

Seriously? How you think i can help you if you give me the full gamemode?
Reply
#9

Quote:

public OnPlayerConnect(playerid)
{
new name [MAX_PLAYER_NAME], query[64];
GetPlayerName(playerid, name, sizeof(name));
format(query, sizeof(query), "SELECT `id` FROM `user` WHERE `username` = '%s'", name);
mysql_function_query(manomysql, query, true, "OnUserCheck", "i", playerid);
return 1;
}

What's wrong?
Reply
#10

Someone?

Where is fail in there?
https://imgur.com/a/ke4RQGb

And why I still have syntax error?
Quote:

[14:17:36] [ERROR] CMySQLQuery::Execute[()] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1

In mysql.log dont write where error is exactly...
Reply
#11

someone know?
Reply
#12

please it very important for me :/

I dont believe what all of in here dont know how to fix this syntax problem.... I have mistake in my MySQL codding and please help me solve it :/
Reply
#13

I\'m still need help...
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)