[MYSQL] proper way to do multi-table query??Rep+
#1

Hello guys, I confused this.
I use lots of table to store player's data but on player login, I have to load them all.

now I use this-kind method to loadit, but its slowly.
Can you point a proper way to do this
Код:
	mysql_format(mySQL, query, sizeof query,
		"SELECT * FROM `a` WHERE `id` = '%d';", pid);
	);
	mysql_tquery(mysql, query, "", "d", playerid);
	mysql_format(mySQL, query, sizeof query,
		"SELECT * FROM `b` WHERE `id` = '%d';", pid);
	);
	mysql_tquery(mysql, query, "", "d", playerid);
	mysql_format(mySQL, query, sizeof query,
		"SELECT * FROM `c` WHERE `id` = '%d';", pid);
	);
	mysql_tquery(mysql, query, "", "d", playerid);
	mysql_format(mySQL, query, sizeof query,
		"SELECT * FROM `d` WHERE `id` = '%d';", pid);
	);
	mysql_tquery(mysql, query, "", "d", playerid);
	mysql_format(mySQL, query, sizeof query,
		"SELECT * FROM `e` WHERE `id` = '%d';", pid);
	);
	mysql_tquery(mysql, query, "", "d", playerid);
	mysql_format(mySQL, query, sizeof query,
		"SELECT * FROM `f` WHERE `id` = '%d';", pid);
	);
	mysql_tquery(mysql, query, "", "d", playerid);
	mysql_format(mySQL, query, sizeof query,
		"SELECT * FROM `g` WHERE `id` = '%d';", pid);
	);
	mysql_tquery(mysql, query, "", "d", playerid);




THX.
Reply


Messages In This Thread
[MYSQL] proper way to do multi-table query??Rep+ - by iLuXing - 01.03.2016, 01:09
Re: [MYSQL] proper way to do multi-table query??Rep+ - by itsCody - 01.03.2016, 03:28
Re: [MYSQL] proper way to do multi-table query??Rep+ - by iLuXing - 01.03.2016, 03:52
Re: [MYSQL] proper way to do multi-table query??Rep+ - by Vince - 01.03.2016, 05:27
Re: [MYSQL] proper way to do multi-table query??Rep+ - by iLuXing - 01.03.2016, 05:31

Forum Jump:


Users browsing this thread: 1 Guest(s)