BETWEEN bug?

From: Josh Berkus <josh(at)agliodbs(dot)com>
To: pgsql-sql(at)postgresql(dot)org
Subject: BETWEEN bug?
Date: 2002-07-10 19:35:53
Message-ID: 200207101235.53848.josh@agliodbs.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Folks,

Why does BETWEEN only work for ascending criteria? For example:

jwnet=> select '2002-06-07'::TIMESTAMP BETWEEN '2002-06-29'::TIMESTAMP and
'2002-06-01'::TIMESTAMP;
?column?
----------
f
(1 row)

jwnet=> select '2002-06-07'::TIMESTAMP BETWEEN '2002-06-01'::TIMESTAMP and
'2002-06-29'::TIMESTAMP;
?column?
----------
t
(1 row)

The above behaviour does not seem logical; is this a SQL spec thing, or a bug?

--
-Josh Berkus

Responses

Browse pgsql-sql by date

  From Date Subject
Next Message David Durst 2002-07-10 19:59:24 Insert Function
Previous Message Nathan Hill 2002-07-10 16:24:47 XML to Postgres conversion