Timestamp manipulation

Поиск
Список
Период
Сортировка
От Stephen Quinney
Тема Timestamp manipulation
Дата
Msg-id 20040331104126.GB11932@computing-services.oxford.ac.uk
обсуждение исходный текст
Список pgsql-sql
I am having a bit of difficulty trying to find a solution to this
problem of manipulating timestamps and dates so I hope someone can
enlighten me.

I have a table which contains a column of type timestamp. For each row
I want to find out the dates for the beginning and end of the week
within which the timestamp lies.

e.g. 2004-04-09 16:00:00+01

The beginning of the week (sunday) is:

2004-04-4

and the end of the week (saturday) is:

2004-04-10

Any suggestions as to how to go about this would be great, thanks in
advance.

Stephen Quinney




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

Предыдущее
От: Christopher Browne
Дата:
Сообщение: Re: plpgsql vs. SQL in stored procedures
Следующее
От: Ivan Sergio Borgonovo
Дата:
Сообщение: Re: plpgsql vs. SQL in stored procedures