19.10.2014, 08:11
Quote:
You can use
variable = something; for integers and floats, for strings you have to use format: format(AccountData[playerid][szEmail],sizeof(AccountData[playerid][szEmail]),"%s",inputtext); |
Код:
C:\Users\Monster\Desktop\samp03z_svr_R1_win32\gamemodes\efs.pwn(237) : error 001: expected token: "]", but found "-identifier-" C:\Users\Monster\Desktop\samp03z_svr_R1_win32\gamemodes\efs.pwn(237) : warning 215: expression has no effect C:\Users\Monster\Desktop\samp03z_svr_R1_win32\gamemodes\efs.pwn(237) : error 001: expected token: ";", but found "]" C:\Users\Monster\Desktop\samp03z_svr_R1_win32\gamemodes\efs.pwn(237) : error 029: invalid expression, assumed zero C:\Users\Monster\Desktop\samp03z_svr_R1_win32\gamemodes\efs.pwn(237) : fatal error 107: too many error messages on one line Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 4 Errors.
I can do like this if i want and it works:
pawn Код:
format(szQuery, sizeof(szQuery), "INSERT INTO `accounts` (email) VALUES ('%s')", inputtext);
mysql_function_query(MainPipeline, szQuery, true, "OnQueryFinish", "ii", THREAD_NO_RESULT, playerid);