Re: How to find out the weekday from a date??? - Mailing list pgsql-general

From Tom Lane
Subject Re: How to find out the weekday from a date???
Date
Msg-id 25639.995390711@sss.pgh.pa.us
Whole thread Raw
In response to Re: How to find out the weekday from a date???  (Jose Manuel Lorenzo Lopez <jose-manuel.lorenzo-lopez@ica.conti.de>)
List pgsql-general
Jose Manuel Lorenzo Lopez <jose-manuel.lorenzo-lopez@ica.conti.de> writes:
> I am using Postgresql 7.0.3!

Support for 'dow' in extract() is new in PG 7.1.  Time to update.

Or use the underlying date_part function:

play=> select date_part('dow', now());
 date_part
-----------
         2
(1 row)

seems to work fine in 7.0 as well as 7.1.

            regards, tom lane

pgsql-general by date:

Previous
From: will trillich
Date:
Subject: psql -l
Next
From: "Stephan Szabo"
Date:
Subject: Re: VACUUM ANALYZE