X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 4686C52A7C for ; Thu, 7 Apr 2005 16:50:38 +0100 (BST) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 19181-02 for ; Thu, 7 Apr 2005 15:50:36 +0000 (GMT) Received: from quasar.skima.is (quasar.skima.is [212.30.200.205]) by svr1.postgresql.org (Postfix) with ESMTP id 5F9C953A7E for ; Thu, 7 Apr 2005 16:50:32 +0100 (BST) Received: from gnari ([157.157.159.208] [157.157.159.208]) by quasar.skima.is with ESMTP; Thu, 7 Apr 2005 15:50:30 Z Subject: Re: 9.17.5. Row-wise Comparison From: Ragnar =?ISO-8859-1?Q?Hafsta=F0?= To: tjo@acm.org Cc: pgsql-sql@postgresql.org In-Reply-To: <42553936.2010108@acm.org> References: <200504032037.j33Kb1kh016358@hosting.commandprompt.com> <4254AD87.2030508@acm.org> <13655.1112849262@sss.pgh.pa.us> <42553936.2010108@acm.org> Content-Type: text/plain Date: Thu, 07 Apr 2005 15:51:54 +0000 Message-Id: <1112889114.5742.17.camel@localhost.localdomain> Mime-Version: 1.0 X-Mailer: Evolution 2.0.2 Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.001 tagged_above=0 required=5 tests=AWL X-Spam-Level: X-Archive-Number: 200504/80 X-Sequence-Number: 20973 On Thu, 2005-04-07 at 06:44 -0700, TJ O'Donnell wrote: > it might break in future. > > > if (b > 1) then true > > else if (b = 1 and c > 2) then true > > else if (b = 1 and c = 2 and d > 3) then true > > else false > Your spec sql snippet is like an OR, isn't it, instead > of an AND as I'm reyling on? not really. > After PG is to spec, will the behaviour I now see change? yes > > "TJ O'Donnell" writes: > > > >>I've been using syntax like > >>select a from tbl where (b,c,d) > (1,2,3) > >> to mean > >>select a from t where b>1 and b>2 and d>3 if b=2, c=1 and d=1 then the expression (b,c,d) > (1,2,3) currently evaluates to false, but according to spec, should evaluate to true. gnari