Re: grabbing date of last Sunday?

Поиск
Список
Период
Сортировка
От Raymond O'Donnell
Тема Re: grabbing date of last Sunday?
Дата
Msg-id 48EF767D.5030105@iol.ie
обсуждение исходный текст
Ответ на grabbing date of last Sunday?  ("blackwater dev" <blackwaterdev@gmail.com>)
Ответы Re: grabbing date of last Sunday?  (Michael Glaesemann <grzm@seespotcode.net>)
Список pgsql-general
On 10/10/2008 16:29, blackwater dev wrote:
> How can I grab the date from the last Sunday based on when I run the query?

select
  current_date
    - (extract(dow from current_date) || ' days')::interval;

:-)

Ray.

------------------------------------------------------------------
Raymond O'Donnell, Director of Music, Galway Cathedral, Ireland
rod@iol.ie
Galway Cathedral Recitals: http://www.galwaycathedral.org/recitals
------------------------------------------------------------------

В списке pgsql-general по дате отправления:

Предыдущее
От: "blackwater dev"
Дата:
Сообщение: grabbing date of last Sunday?
Следующее
От: Pascal Cohen
Дата:
Сообщение: Re: Improve dump and restore time