I believe your problem is that versions of MySQL prior to 4.1 (i think) do not allow subqueries. You may try rewriting your query as a join.
On Tue, 28 Dec 2004 12:14:06 -0600, Adam Ernst <[EMAIL PROTECTED]> wrote: > I'm trying to do the following SELECT statement: > > SELECT * FROM matches WHERE question_id = ANY (SELECT server_id FROM > questions WHERE results_id = 'MyID') > > I've tried rephrasing it as: > > SELECT * FROM matches WHERE question_id IN (SELECT server_id FROM > questions WHERE questions.results_id = 'MyID') > > And even: > > SELECT * FROM matches WHERE question_id IN (SELECT q.server_id FROM > questions as q WHERE q.results_id = 'MyID') > > But no go--in all cases, I get an syntax error near the first > parentheses. > > Any suggestions? This is on MySQL 4.0.22-standard. > > Thanks, > > Adam Ernst > > -- > MySQL General Mailing List > For list archives: http://lists.mysql.com/mysql > To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED] > > -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]