I didn't remove the table prefix, i added it. That ist the errormessage onli with this option
"User has never posted (also count in social groups and blogs)" selectet and clicked on "test":
Quote:
Datenbankfehler in vBulletin 4.1.2:
Invalid SQL:
SELECT
`user`.*
FROM
vb_user AS user
LEFT JOIN vb_groupmessage ON `groupmessage`.postuserid = `user`.userid
LEFT JOIN vb_blog_text ON `blog_text`.bloguserid = `user`.userid
WHERE
`user`.`posts` = 0 AND `groupmessage`.gmid IS NULL AND `blog_text`.blogtextid IS NULL AND `user`.`userid` NOT IN (0);
MySQL-Fehler : Unknown column 'groupmessage.gmid' in 'where clause'
Fehler-Nr. : 1054
Fehler-Zeit : Monday, 21.03.2011 @ 20:23:28
Datum : Monday, 21.03.2011 @ 20:23:28
Skript : vbroot/admincp/users_cleanup.php?do=test
Referrer : vbroot/admincp/users_cleanup.php?do=add
IP-Adresse : xXx
Benutzername : xXx
Klassenname : vB_Database
MySQL-Version : 5.1.43-nmm4-log
|
I was first trying to hardcode the prefix. Than i got the variable to work.
That are the only lines i changed:
Code:
// social groups
$join[] = 'LEFT JOIN ' . TABLE_PREFIX . 'groupmessage ON ' . TABLE_PREFIX .'groupmessage.postuserid = `user`.userid';
$where[] = TABLE_PREFIX .'groupmessage.gmid IS NULL';
// blog
if ($vbulletin->products['vbblog'])
{
$join[] = 'LEFT JOIN ' . TABLE_PREFIX . 'blog_text ON ' . TABLE_PREFIX .'blog_text.bloguserid = `user`.userid';
$where[] = TABLE_PREFIX .'blog_text.blogtextid IS NULL';
}
break;