Re: BUG #5740: contrib/spi/moddatetime.c doesn't work with timezones.

Поиск
Список
Период
Сортировка
От Dimitri Fontaine
Тема Re: BUG #5740: contrib/spi/moddatetime.c doesn't work with timezones.
Дата
Msg-id m2iq0eqecz.fsf@2ndQuadrant.fr
обсуждение исходный текст
Ответ на BUG #5740: contrib/spi/moddatetime.c doesn't work with timezones.  ("Dirk Heinrichs" <dirk.heinrichs@altum.de>)
Ответы Re: BUG #5740: contrib/spi/moddatetime.c doesn't work with timezones.
Список pgsql-bugs
Dirk Heinrichs <dirk.heinrichs@altum.de> writes:
> Please find the patch attached. It's against 8.4.5.
>
>  extern Datum moddatetime(PG_FUNCTION_ARGS);
> +extern Datum moddatetimetz(PG_FUNCTION_ARGS);
[...]
> +CREATE OR REPLACE FUNCTION moddatetimetz()
> +RETURNS trigger
> +AS 'MODULE_PATHNAME'
> +LANGUAGE C;

You can also do AS 'MODULE_PATHNAME', 'c_function_name' and maintain a
single C function that copes with both timestamp and timestamptz
arguments, that's what I had in mind: you still declare two functions at
the SQL level, though.

Regards,
--
Dimitri Fontaine
http://2ndQuadrant.fr     PostgreSQL : Expertise, Formation et Support

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

Предыдущее
От: "Tian Shiquan"
Дата:
Сообщение: BUG #5742: cannot alter column
Следующее
От: Dirk Heinrichs
Дата:
Сообщение: Re: BUG #5740: contrib/spi/moddatetime.c doesn't work with timezones.