This is the error that I am getting.
[code]
Database error in vBulletin 2.2.1:
Invalid SQL: -1209600
AND (usergroupid=5
OR usergroupid=6
OR usergroupid=7
OR usergroupid=9
OR usergroupid=10
OR usergroupid=2)
ORDER BY randNum
LIMIT 1
mysql error:
mysql error number:
Date: Thursday 07th of March 2002 06:46:03 AM
[\code]
This is the code as I have it in my index.php3 file.
Code:
$newmember=$DB_site->query_first("SELECT userid,username,userid*0+RAND() AS randNum
FROM user
WHERE userid<>$daybits[1] AND posts>99
AND lastactivity>time()-(86400*14)
AND (usergroupid=5
OR usergroupid=6
OR usergroupid=7
OR usergroupid=9
OR usergroupid=10
OR usergroupid=2)
ORDER BY randNum
LIMIT 1");
I have tried it with and without the "s around the time() section. Wierd thing is that I can run this query though mysqladmin.
Chris