Re: Time zone offset in to_char()

Поиск
Список
Период
Сортировка
От Alban Hertroys
Тема Re: Time zone offset in to_char()
Дата
Msg-id 520EC025-CFF0-4558-BA24-35B141A3818D@gmail.com
обсуждение исходный текст
Ответ на Re: Time zone offset in to_char()  (Adrian Klaver <adrian.klaver@aklaver.com>)
Список pgsql-general
> On 11 Jan 2024, at 18:27, Adrian Klaver <adrian.klaver@aklaver.com> wrote:
>
> On 1/11/24 08:48, Adrian Klaver wrote:
>> On 1/11/24 08:04, Alban Hertroijs wrote:
>
>>> The drawback, as mentioned, being that we need to maintain those functions in each deployment, which is a bit of a
hassle(albeit a minor one) because we need to customise both the TDV side and the PostgreSQL side in that case. Our
preferredsolution would be to just add a few entries to the TDV database-specific capabilities file (as described in my
initialmessage) 
>> Are you referring to?:
>> "It currently have this:
>> ToDatetimeOffsetNL(~any) : ciscache.ToDatetimeOffsetNL($1)
>> ToDatetimeOffset(~any,~any) : ciscache.ToDatetimeOffset($1, $2)
>> "
>
> It finally dawned on me, you want to replace the user defined functions above with Postgres builtins only. Try as I
mightI could not come with that solution. 

Exactly. I was having the same problem of finding a solution, quite to my surprise.

>> I thought the issue there was maintaining the two Postgres functions?

Yup, those two functions in fact.

There will be at least 3 separate deployments, while maintenance of the database(-schema) contents is the
responsibilityof the 3rd party application (TDV). PG is used as a caching DB here, we therefore intend to treat the
datain it as volatile; it shouldn’t hurt if we decide to recreate the caches from scratch from source data. Having
customcode in there not under control of the 3rd party application breaks that guideline. 

If they’re necessary, then so be it, but I can’t shake the feeling that we can achieve this without custom code in the
database.

Regards,

Alban Hertroys
--
There is always an exception to always.







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

Предыдущее
От: Alban Hertroys
Дата:
Сообщение: Re: Time zone offset in to_char()
Следующее
От: Jeremiah Bauer
Дата:
Сообщение: Refresh Materialized View Issue