Re: [SQL] Date select question...

2004-01-08 Thread Tom Lane
Lance Munslow <[EMAIL PROTECTED]> writes: > [ why do these act differently: ] > select * from test where test_date between '20041001' and '20041101'; > select * from test where test_date between 20041001 and 20041101; In the latter case the constants are integers, not dates. IMHO the best policy

[SQL] Date select question...

2004-01-08 Thread Lance Munslow
I have the following table: Table "public.test" Column | Type | Modifiers ---+--+--- test_date | date | with the following data: test_date 2004-10-31 2004-11-01 (2 rows) Why does the query: select * from test where test_date between '20041001' and