The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
Ok, I'm trying to created a list of users who have data entered in their "field8" in the "userfield" table.
I did this: [QUOTE] require("/home/newbeetle/public_html/vbulliten/admin/config.php"); $db=mysql_connect($servername,$dbusername,$dbpassw ord); mysql_select_db($dbname); $query = "SELECT * FROM userfield WHERE field8 = ''"; $resultlatest = mysql_query($query,$db); while ($latest_array = mysql_fetch_array($resultlatest)) { echo "<A HREF=\"http://forums.newbeetle.org/member.php?action=getinfo&userid=$latest_array[userid]\">$latest_array[username]</A> } |
#2
|
||||
|
||||
Change your query to this:
SELECT * FROM userfield LEFT JOIN user ON user.userid=userfield.userid WHERE userfield.field8=''; |
#3
|
|||
|
|||
Thanks so much. That worked beautifully.
|
Thread Tools | |
Display Modes | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|