The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
Sql queries
I'm trying to write 2 queries and a bit of php with them.
One query which will pull a count of the members in a certain membergroup (not usergroup) and another which will pull the information in the user and userfield tables, again, based on membergroup. can someone give me a hand figuring this out please? |
#2
|
|||
|
|||
If it's not an addon usergroup,
[sql] SELECT usergroupid, COUNT(userid) AS membershipcount FROM user GROUP BY usergroupid[/sql] If it's an addon usergroup (a "membergroup", as you say, I guess), it requires PHP handling to explode the membergroupids and use in_array() to find hits. |
#3
|
|||
|
|||
so if I understand correctly, if it is a membergroupid (from the user table in vb) I have to set up an array first in order to extract a specific group out of it?
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|