checking notifies.php - you folks will see.... that this query is used for the latter work in the code:
Code:
SELECT
NotifyQueue.Email as ID1,
NotifyQueue.Msg as ID2,
Profiles.RealName as Name,
Profiles.Email,
NotifyMsgs.Subj,
NotifyMsgs.HTML as Body
FROM NotifyQueue
INNER JOIN NotifyMsgs
ON (NotifyMsgs.ID = NotifyQueue.Msg)
INNER JOIN Profiles
ON (Profiles.ID = NotifyQueue.Email)
WHERE
NotifyQueue.`From` = 'Profiles' AND
Profiles.EmailNotify = 'NotifyMe' AND
Profiles.EmailFlag = 'HTML'";
this query has no variables in it (it is ok as is) - so you can run it in mysql - and see what happens.... doing that results in:
Code:
SELECT NotifyQueue.Email AS ID1, NotifyQueue.Msg AS ID2, Profiles.RealName AS Name, Profiles.Email, NotifyMsgs.Subj, NotifyMsgs.HTML AS Body
FROM NotifyQueue
INNER JOIN NotifyMsgs ON ( NotifyMsgs.ID = NotifyQueue.Msg )
INNER JOIN Profiles ON ( Profiles.ID = NotifyQueue.Email )
WHERE NotifyQueue.`From` = 'Profiles'
AND Profiles.EmailNotify = 'NotifyMe'
AND Profiles.EmailFlag = 'HTML'
LIMIT 0 , 30
MySQL said:
#1054 - Unknown column 'Profiles.RealName' in 'field list'
Checking the Profiles table... there is NO
field - thus - the bug/problem.
Changing
Code:
Profiles.RealName AS Name
to
Code:
Profiles.NickName AS Name
results in an SQL query with no errors.
I'm I a genius or what. 
Give it a try on your site(s). I did not test it - just ran some queries in mysql to test the faulty query and fix to end up with a "clean" one.
Smoge
Bookmarks