Icon View Thread

The following is the text of the current message along with any replies.
Messages 1 to 2 of 2 total
Thread SQL no longer works
Sat, Nov 11 2006 6:57 PMPermanent Link

"Scott Martin"
This used to work in older version, does not work in 599 r2

If this was not supposed to work due to an error, how to re-write.
If it is valid, can you please fix.

error: Column references must either be in aggregate functions or grouped on C.ClientID

Regards,
Scott.

SELECT C.ClientID,MIN(C.DisplayName) AS DisplayName FROM Clients C
LEFT JOIN ClientRolodex CR ON (C.ClientID = CR.ClientID)
INNER JOIN Rolodex R ON (CR.RolodexID=R.RolodexID)
WHERE R.Description = 'Seminar Attendee'
AND
NOT EXISTS (
SELECT C.ClientID,MIN(C.DisplayName) AS DisplayName FROM ClientRolodex bCR
INNER JOIN Rolodex R ON (bCR.RolodexID=R.RolodexID)
WHERE (bCR.ClientID = C.ClientID)
AND R.Description = 'Client - Dan'
)
GROUP BY C.ClientID

Sat, Nov 11 2006 6:59 PMPermanent Link

"Scott Martin"
Oh my ... wrong NG, wrong product ... oops.

Please cancel/disregard post.

Regards,
Scott.

Image