Mysql update R7
#1

So i have this code. It should update my car stats
Код:
		UpdateCarFlo(car, "PosX", CarInfo[car][PosX]);
		UpdateCarFlo(car, "PosY", CarInfo[car][PosY]);
......
Код:
public UpdateCarFlo(sCarId, sValue[], Float:sFlo)
{
	new query[140];
	format(query, sizeof(query), "UPDATE scriptcars SET %s = %f WHERE ID = %d", sValue, sFlo, sCarId);
	mysql_function_query(gSQL, query, false, "SendQuery", "");
}
But i got the problem, it only updates the first public. As i can see from mysql_log:
Код:
[17:13:42] >> mysql_query_callback( Connection handle: 1 )
[17:13:42] >> mysql_query_callback( Connection handle: 1 )
[17:13:42] >> mysql_query_callback( Connection handle: 1 )
[17:13:42] Passing query UPDATE scriptcars SET PosX = 664.403991 WHERE ID = 0 | 
[17:13:42] >> mysql_query_callback( Connection handle: 1 )
[17:13:42] >> mysql_query_callback( Connection handle: 1 )
[17:13:42] >> mysql_query_callback( Connection handle: 1 )
[17:13:42] ProcessQueryThread(SendQuery) - Query was successful. (UPDATE scriptcars SET PosX = 664.403991 WHERE ID = 0)
[17:13:42] CMySQLHandler::ProcessQueryThread() - Data is getting passed to ->ProcessTick()
[17:13:42] >> mysql_query_callback( Connection handle: 1 )
[17:13:42] >> mysql_query_callback( Connection handle: 1 )
[17:13:42] >> mysql_query_callback( Connection handle: 1 )
[17:13:42] >> mysql_query_callback( Connection handle: 1 )
[17:13:42] >> mysql_query_callback( Connection handle: 1 )
[17:13:42] >> mysql_query_callback( Connection handle: 1 )
What could be the problem?
Reply


Messages In This Thread
Mysql update R7 - by Larry123 - 24.02.2014, 14:20
Re: Mysql update R7 - by Misiur - 24.02.2014, 14:29
Re: Mysql update R7 - by Larry123 - 24.02.2014, 16:08

Forum Jump:


Users browsing this thread: 1 Guest(s)