Search Postgresql Archives

Re: using between with dates

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 29 April 2010 14:55, Geoffrey Myers <geof@xxxxxxxxxxxxxxxxxxxxx> 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?


You need to cast that last date, so:

ship_date between '04/30/2010' AND '04/30/2010'::date + 14

Thom

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux