General SQL Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
 
Go Back   Dev Articles Community ForumsDatabasesGeneral SQL Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
 
Unread Dev Articles Community Forums Sponsor:
Stay one step ahead of the competition. Evaluate and give feedback on some of the hottest web development tools on the market today. Make your opinion heard! Click Here
  #1  
Old January 7th, 2003, 10:33 PM
jantichap jantichap is offline
Junior Member
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Jan 2003
Location: Thailand
Posts: 1 jantichap User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Post Help me query please!!!!

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

Reply With Quote
  #2  
Old January 8th, 2003, 06:21 AM
peeyush peeyush is offline
Junior Member
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Nov 2002
Location: India
Posts: 17 peeyush User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Send a message via Yahoo to peeyush
hi jantichap

You cannot execute subqueries in MySQL, if you are using this query in a program you need to breakup the query in two parts, one will collect userid and pass it to other query.

Reply With Quote
Reply

Viewing: Dev Articles Community ForumsDatabasesGeneral SQL Development > Help me query please!!!!


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 2 hosted by Hostway