X-Original-To: pgsql-jdbc-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 7774B5659A for ; Thu, 10 Mar 2005 20:43:36 +0000 (GMT) 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 54915-04 for ; Thu, 10 Mar 2005 20:43:35 +0000 (GMT) Received: from fc1-dev-01.wavenet.com.ar (unknown [200.49.155.145]) by svr1.postgresql.org (Postfix) with ESMTP id AD6FF56589 for ; Thu, 10 Mar 2005 20:43:33 +0000 (GMT) Received: from 168-226-185-75.speedy.com.ar ([168.226.185.75] helo=192.168.0.14) by fc1-dev-01.wavenet.com.ar with esmtp (Exim 4.44) id 1D9UUM-0008QH-LM; Thu, 10 Mar 2005 17:42:34 -0300 Subject: Re: PostGreSQL Date Query? From: Diego Gil To: Lennie De Villiers Cc: JDBC Postgresql In-Reply-To: References: Content-Type: text/plain; charset=UTF-8 Organization: ADMIN S.A. Date: Thu, 10 Mar 2005 17:44:54 -0300 Message-Id: <1110487494.5163.10.camel@roadwarrior.adminsa.com> Mime-Version: 1.0 X-Mailer: Evolution 2.0.2 (2.0.2-3) Content-Transfer-Encoding: quoted-printable X-PopBeforeSMTPSenders: diego@adminsa.com, info@adminsa.com, listas@adminsa.com, marseille@adminsa.com X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - fc1-dev-01.wavenet.com.ar X-AntiAbuse: Original Domain - postgresql.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - adminsa.com X-Source: X-Source-Args: X-Source-Dir: X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.365 tagged_above=0 required=5 tests=AWL, FORGED_RCVD_HELO X-Spam-Level: X-Archive-Number: 200503/104 X-Sequence-Number: 12496 Maybe you have a wrong datestyle format. Try a query with '01/01/2005' and '01/28/2005' range, in month-day-year format. Diego. El mar, 08-03-2005 a las 23:51 +0200, Lennie De Villiers escribi=C3=B3: > Hi, >=20 >=20 > I'm using Java together with PostGreSQL database. >=20 >=20 >=20 > I'm having a problem with a date query, when I write: >=20 >=20 >=20 > select sRescheduleDate, * from tbl_leads >=20 > where sRescheduleDate >=3D '01/01/2005' AND sRescheduleDate <=3D > '28/01/2005' >=20 > and bRescheduleCall =3D true =20 >=20 >=20 >=20 > the query also return the values for "01/04/2005" where it should only > return those between that date range. >=20 > Anyone can help me. >=20 >=20 >=20 > Using Java 2 SE 1.4.2, PostGreSQL 8.0 >=20 >=20 > Kind Regards, >=20 >=20 >=20 > Lennie De Villiers >=20 >=20 >=20 >=20 >=20