jantichap Posted January 8, 2003 Share Posted January 8, 2003 select luser.userid,luser.firstname,luser.lastname from luser where luser.Pos = \'Teacher\'and luser.userid not in (select sectionuser.userid from sectionuser where sectionuser.courseid = \'204105\'and sectionuser.SectionID = \'1\' and sectionuser.Semester = \'2\') ORDER BY luser.UserID this query i can use in other database server but i can\'t use in MySQL version 4.0.2-alpha-nt please!!! help me to convert my query can use in MySQL ....thank Quote Link to comment https://forums.phpfreaks.com/topic/24-help-me-query-please/ Share on other sites More sharing options...
pallevillesen Posted January 8, 2003 Share Posted January 8, 2003 A few typos, try: SELECT luser.userid,luser.firstname,luser.lastname FROM luser WHERE (luser.Pos = \'Teacher\') AND ( luser.userid NOT IN ( SELECT sectionuser.userid FROM sectionuser WHERE (sectionuser.courseid = \'204105\') AND (sectionuser.SectionID = \'1\') AND (sectionuser.Semester = \'2\') ) ) ORDER BY luser.UserID Try it, P., denmark select luser.userid,luser.firstname,luser.lastname from luser where luser.Pos = \'Teacher\'and luser.userid not in (select sectionuser.userid from sectionuser where sectionuser.courseid = \'204105\'and sectionuser.SectionID = \'1\' and sectionuser.Semester = \'2\') ORDER BY luser.UserID this query i can use in other database server but i can\'t use in MySQL version 4.0.2-alpha-nt please!!! help me to convert my query can use in MySQL ....thank Quote Link to comment https://forums.phpfreaks.com/topic/24-help-me-query-please/#findComment-62 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.