"Chris Ruprecht" <[EMAIL PROTECTED]> writes:
> phone=# select * from phonelog where cdate > 2001-05-18 order by cdate limit
> 2 ;
Try
select * from phonelog where cdate > '2001-05-18' order by cdate limit 2
I think it's interpreting your query as where cdate > 1978 (result of
integer subexpression) and then doing some weird integer-to-date
conversion. In general, any constant of a non-numeric datatype needs
to be quoted in SQL queries.
regards, tom lane
---------------------------(end of broadcast)---------------------------
TIP 6: Have you searched our list archives?
http://www.postgresql.org/search.mpl