• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

SQL Query

Kavvson

Gdy boli cie glowa wez
Joined
Jun 25, 2008
Messages
1,177
Reaction score
72
Location
Poland
I know its wrong but how to make it working.

PHP:
$v1 = $SQL->query ('SELECT COUNT(*) as `vocation` FROM `players` WHERE `rank_id` IN (SELECT `id` FROM `guild_ranks` WHERE `guild_id` = '.$guild_id.') WHERE `vocation`=1;')->fetch();
 
Code:
SELECT COUNT(*) as `vocation` FROM `players` WHERE `rank_id` IN (SELECT `id` FROM `guild_ranks` WHERE `guild_id` = '.$guild_id.') [COLOR="red"]AND[/COLOR] `vocation`= 1;

What u need exactly ?
 
Counting vocations in a guild


@Thanks your script work properly.

Btw check my other topic bit lower if you are a good sql mate
 
Back
Top