Help (MySQL)...
#1

I developed a code which the variable "items" has a capacity to store 145 items, which I made the following code to quickly save the items (which by the way, I do not know if this is the fastest way to list all items , I saw something out there regarding the use of sscanf but not quite understand .. so I opted for this method)

Код:
        for(new items = 0; items < MAX_ITEMS; items++)
	{
		format(string, sizeof(string), "%i|',",
		pInfo[playerid][jItem][items]);
	}
	mysql_format(mysql, query, sizeof(query), "\
	UPDATE `users` SET `Items`='%s' WHERE `Nombre` = '%s'",
	string,
	GetName(playerid));
 	mysql_tquery(mysql, query, "", "");
The question is simple, how would it be to load all items ?, and I'm using the symbol "|" to separate values and power load, the detail is that I can not assign each value to "pInfo[playerid][jItem][...]", without more, a greeting.
Reply


Messages In This Thread
Help (MySQL)... - by Unrea1 - 04.10.2016, 22:39
Re: Help (MySQL)... - by PrO.GameR - 04.10.2016, 23:31
Re: Help (MySQL)... - by Unrea1 - 04.10.2016, 23:39
Re: Help (MySQL)... - by Vince - 05.10.2016, 05:23
Respuesta: Re: Help (MySQL)... - by Unrea1 - 23.10.2016, 21:57
Respuesta: Help (MySQL)... - by Unrea1 - 24.10.2016, 16:55
Respuesta: Help (MySQL)... - by Unrea1 - 26.10.2016, 19:34
Re: Help (MySQL)... - by Gammix - 26.10.2016, 20:02

Forum Jump:


Users browsing this thread: 1 Guest(s)