PDA

View Full Version : what's wrong with this mysql query?


N!ck
03-10-2002, 04:40 PM
SELECT announcement.title, announcement.userid, announcement.startdate, announcement.pagetext, user2.username as username FROM announcement LEFT JOIN user AS user2 ON (user.userid = announcement.userid) ORDER BY startdate, endate LIMIT 5

I'm getting an error (#1109).

Admin
03-10-2002, 04:49 PM
Change user.userid to user2.userid in the JOIN.

N!ck
03-10-2002, 04:53 PM
wow. now that's service. thanks!

Admin
03-10-2002, 04:57 PM
:)