Received: from bjke.com (firewall-user@ganymede.bjke.com [144.210.8.38]) by hub.org (8.9.3/8.9.3) with ESMTP id RAA21226 for ; Mon, 7 Jun 1999 17:29:15 -0400 (EDT) (envelope-from djackson@cpsgroup.com) Received: by bjke.com; id QAA17652; Mon, 7 Jun 1999 16:29:13 -0500 (CDT) Received: from unknown(144.210.12.10) by gauntlet.bjke.com via smap (4.1) id xma017595; Mon, 7 Jun 99 16:29:04 -0500 Received: by cpsmail with Internet Mail Service (5.5.2448.0) id ; Mon, 7 Jun 1999 16:29:33 -0500 Message-ID: From: "Jackson, DeJuan" To: Chris Bitmead Cc: pgsql-sql@hub.org Subject: RE: [SQL] Slashdot Query Date: Mon, 7 Jun 1999 16:29:32 -0500 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2448.0) Content-Type: text/plain Is it me or does this query actually make any sense??? Is story.datetime a column in your table? You might be able to rewrite this query. I don't know if the ordering you were trying for is needed, but SELECT oid, title, image FROM category* WHERE EXISTS(SELECT 1 FROM story WHERE story.approved AND story.category = category.oid); should give you the same information. Hope this helps, -DEJ > Chris Bitmead writes: > > SELECT category.oid, category.title, category.image FROM story, > > category* WHERE story.category = category.oid AND story.approved GROUP > > BY category.oid, category.title, category.image ORDER BY min(datetime); > > pqReadData() -- backend closed the channel unexpectedly. > > This probably means the backend terminated abnormally > > before or while processing the request. > > We have lost the connection to the backend, so further processing is > > impossible. Terminating. > > This is a known problem --- see my pghackers email of a few days ago, > "inherited GROUP BY is busted". > > regards, tom lane