'%e' - MySQL R7
#1

Am I the only one encountering the problem where the '%e' prefix in format does not work (escapes incorrectly)?
Another question, what's the " | d" at the end of the first line below?
(Escaping using mysql_real_escape_string function and the '%s' works just as fine)

Logs:
Код:
Passing query SELECT `test` FROM `table` WHERE `name` = 'e' LIMIT 0,1 | d
ProcessQueryThread(OnAPublic) - Query was successful. (SELECT `test` FROM `table` WHERE `name` = 'e' LIMIT 0,1)
Code:
pawn Код:
new query[64];
format(query, sizeof(query), "SELECT `test` FROM `table` WHERE `name` = '%e' LIMIT 0,1", GetName(playerid));
mysql_function_query(Handler, query, true, "OnAPublic", "d", playerid);

forward OnAPublic(playerid);
public OnAPublic(playerid)
{
     // ......
     return 1;
}

GePlayerName(playerid)
{
     new name[MAX_PLAYER_NAME]
     GetPlayerName(playerid, name, sizeof(name));
     return name;
}
Reply


Messages In This Thread
'%e' - MySQL R7 - by Loot - 14.12.2013, 02:45
Re: '%e' - MySQL R7 - by Loot - 15.12.2013, 13:20
Re: '%e' - MySQL R7 - by Vince - 15.12.2013, 13:25
Re: '%e' - MySQL R7 - by Loot - 15.12.2013, 13:35
Re: '%e' - MySQL R7 - by Loot - 16.12.2013, 16:24
Re: '%e' - MySQL R7 - by dominik523 - 16.12.2013, 18:40
Re: '%e' - MySQL R7 - by Loot - 16.12.2013, 21:34
Re: '%e' - MySQL R7 - by Patrick - 16.12.2013, 22:01
Re: '%e' - MySQL R7 - by Loot - 16.12.2013, 23:18
Re: '%e' - MySQL R7 - by Loot - 21.12.2013, 02:38

Forum Jump:


Users browsing this thread: 1 Guest(s)