Re: using between with dates - Mailing list pgsql-general

From Geoffrey
Subject Re: using between with dates
Date
Msg-id 4BD9931B.4020507@serioustechnology.com
Whole thread Raw
In response to using between with dates  (Geoffrey <lists@serioustechnology.com>)
List pgsql-general
Geoffrey wrote:
> I'm trying the following:
>
> ship_date between '04/30/2010' AND '04/30/2010' + 14
>
> But this returns:
>
> ERROR:  invalid input syntax for integer: "04/30/2010"
>
> Can I use between with dates?


Got it:

ship_date between '04/30/2010' and timestamp '04/30/2010' + interval '14
day'


--
Until later, Geoffrey

"I predict future happiness for America if they can prevent
the government from wasting the labors of the people under
the pretense of taking care of them."
- Thomas Jefferson

pgsql-general by date:

Previous
From: Geoffrey
Date:
Subject: using between with dates
Next
From: Adrian Klaver
Date:
Subject: Re: using between with dates