MySQL loads random values
#1

So I have a problem with my mysql data loading.
I want it to load the stuff from my database, but it loads some random values.
I checked, if there was a typo in the field idx, but there was not - those values, that it loaded were not even in my mysql database.

Here's the code
Код:
format(query, sizeof(query), "SELECT * FROM `players` WHERE `name` = '%s'", playerName(playerid));
	mysql_function_query(g_Handle, query, true, "LoadAcc", "d", playerid);
LoadAcc
Код:
	PlayerInfo[playerid][kSQLID]			= cache_get_row_int(0, 0, g_Handle),
	PlayerInfo[playerid][kAdmin]			= cache_get_row_int(0, 3, g_Handle),
	PlayerInfo[playerid][kBanned]			= cache_get_row_int(0, 5, g_Handle),
	PlayerInfo[playerid][kLang]			= cache_get_row_int(0, 6, g_Handle),
	PlayerInfo[playerid][kWarn]	         	= cache_get_row_int(0, 7, g_Handle),
	PlayerInfo[playerid][kMoney]			= cache_get_row_int(0, 9, g_Handle),
	PlayerInfo[playerid][kSkin]			= cache_get_row_int(0, 10, g_Handle),
	PlayerInfo[playerid][kScore]			= cache_get_row_int(0, 13, g_Handle);

	cache_get_row(0, 1, PlayerInfo[playerid][kName], g_Handle, 70);
	cache_get_row(0, 2, PlayerInfo[playerid][kPW], g_Handle, 130);
	cache_get_row(0, 14, PlayerInfo[playerid][kSalt], g_Handle, 31);
Reply


Messages In This Thread
MySQL loads random values - by tsonn1 - 26.08.2014, 12:45
Re: MySQL loads random values - by Dotayuri - 26.08.2014, 13:21
Re: MySQL loads random values - by tsonn1 - 26.08.2014, 13:29
Re: MySQL loads random values - by Dotayuri - 26.08.2014, 13:57
Re: MySQL loads random values - by tsonn1 - 26.08.2014, 14:17
Re: MySQL loads random values - by Dotayuri - 26.08.2014, 14:21
Re: MySQL loads random values - by IceCube! - 26.08.2014, 14:27
Re: MySQL loads random values - by Dotayuri - 26.08.2014, 14:33
Re: MySQL loads random values - by tsonn1 - 26.08.2014, 16:50

Forum Jump:


Users browsing this thread: 2 Guest(s)