Re: [FeatureRequest] Base Convert Function
От | Robert Haas |
---|---|
Тема | Re: [FeatureRequest] Base Convert Function |
Дата | |
Msg-id | AANLkTin40n=1nWBKkLmaWOaBrZ6txh+MR4+5wuvc0WMH@mail.gmail.com обсуждение исходный текст |
Ответ на | [FeatureRequest] Base Convert Function (Tomáš Mudruňka <tomas@mudrunka.cz>) |
Ответы |
Re: [FeatureRequest] Base Convert Function
Re: [FeatureRequest] Base Convert Function |
Список | pgsql-hackers |
2010/12/21 Tomáš Mudruňka <tomas@mudrunka.cz>: > Is there possibility of having internal base converting function in PgSQL? > There are already functions for converting between decimal and hexadecimal > notations i think pgsql can be able to convert between number with radixes > from 1 to 36 (actually fast (de)encoding base36 is what i need)... It should be pretty easy to write such a function in C, perhaps using strtol() or strtoul(). Because PostgreSQL uses an extensible architecture, you could load such a function into your copy of PostgreSQL and use it in your environment even if it weren't part of the core distribution. There are a number of existing "contrib" modules that you can look at for examples of how to do this. Whether or not we'd accept a patch to add such a function to core or contrib, I'm not sure. Nobody's written one yet... -- Robert Haas EnterpriseDB: http://www.enterprisedb.com The Enterprise PostgreSQL Company
В списке pgsql-hackers по дате отправления: