Received: from mx99.openu.ac.il (arbel.openu.ac.il [147.233.32.4]) by hub.org (8.9.3/8.9.1) with ESMTP id LAA87246 for ; Thu, 29 Apr 1999 11:03:44 -0400 (EDT) (envelope-from herouth@oumail.openu.ac.il) Received: from talmon.openu.ac.il (talmon.openu.ac.il [147.233.32.11]) by mx99.openu.ac.il (Postfix) with ESMTP for id BCBFD4BD4F; Thu, 29 Apr 1999 18:03:27 +0300 (IDT) Received: from [147.233.159.109] (mac-herouth.pc.openu.ac.il) by talmon.openu.ac.il (Netscape Messaging Server 3.54) with ESMTP id AAA116C; Thu, 29 Apr 1999 18:05:36 +0300 X-Sender: herouth@shaked.cc.openu.ac.il Message-Id: In-Reply-To: <37286C86.8E0472A6@bigfoot.com> References: Your message of Fri, 23 Apr 1999 08:42:55 -0600 (MDT) <199904231442.IAA17294@trillium.nmsu.edu> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Date: Thu, 29 Apr 1999 18:03:54 +0300 To: Chris Bitmead , pgsql-sql@postgreSQL.org From: Herouth Maoz Subject: Re: [SQL] Finding the "most recent" rows At 17:28 +0300 on 29/04/1999, Chris Bitmead wrote: > > You say that a table is "considered an unordered set". But surely a > table is not an unordered set if you've specified an ORDER BY clause? > This idea is so nice, it would be ashame to dismiss it too quickly. Charming, but alas, non standard. Moreover, what if you want to get the maximal value, but order in an ascending in the output? No, if you want compatible SQL, you won't use DISTINCT ON, and you will specify the exact method of picking the distinguished value. Furthermore, ORDER BY has to be a late stage, if it should work on the entire results of unions, for example, or the result of groups. Herouth -- Herouth Maoz, Internet developer. Open University of Israel - Telem project http://telem.openu.ac.il/~herutma