Re: rewriting this SQL statement to remove subselect

From: Date: Mon, 12 Feb 2001 13:57:26 +0000
Subject: Re: rewriting this SQL statement to remove subselect
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-39258@lists.php.net to get a copy of this message
On Monday 12 February 2001 01:31, Scott Mebberson wrote: > I understand that as of version 3.24, MySQL will support subselects. > But untill then (because 3.23 is the latest stable release) I need to > convert this SQL satement into something that can be used with v3.2? - > the version just before the latest release. > > $search = "SELECT count(search_table.word) as score, > search_table.qid,page_data.contents > FROM search_table,page_data > WHERE page_data.pID = search_table.qid AND search_table.word > IN($querywords) > GROUP BY search_table.qid > ORDER BY score DESC"; Uh, perhaps I'm blind and/or dumb, but I just can't find a subselect in that query. The query as written here should run fine in any MySQL version -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) Nothing is more dangerous than an idea if it's the only one you have. - Emil-Auguste Chartier, "Propos sur la religion", 1938

« previous php.general (#39258) next »