Re: Is there a better way to do this?

Поиск
Список
Период
Сортировка
От D. Dante Lorenso
Тема Re: Is there a better way to do this?
Дата
Msg-id 46D499E3.504@lorenso.com
обсуждение исходный текст
Ответ на Is there a better way to do this?  (Wei Weng <wweng@kencast.com>)
Ответы Re: Is there a better way to do this?
Список pgsql-general
Wei Weng wrote:
> I want to implement something like the following:
> CREATE OR REPLACE FUNCTION AddDays

You don't know how many seconds are in a day, so just add the days using
SQL.

    RETURN time + (days || ' days')::INTERVAL;

You don't even need to make that a function, just do that you your SQL
directly.

-- Dante

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

Предыдущее
От: "Rodrigo De León"
Дата:
Сообщение: Re: Is there a better way to do this?
Следующее
От: Michael Glaesemann
Дата:
Сообщение: Re: Is there a better way to do this?