Re: [SQL] SQL Syntax / Logic question

2001-10-08 Thread Thurstan R. McDougle
To help you understand SQL I should point out that your version would work (assuming only 1 school per person) if you just left the friends out of the FROMs for the sub-selects:- select frienda, friendb from friends where (select schools.school from schools as schoolsa where friends.frienda = sc

Re: [SQL] SQL Syntax / Logic question

2001-10-04 Thread Josh Berkus
Mike, > select frienda, friendb from friends where (select > schools.school from friends,schools where friends.frienda = > schools.person) = (select schools.school from friends,schools where > friends.friendb = schools.person); Too complicated. You need to learn how to use JOINS and table alias