Re: Converting BYTEA from/to BIGINT

Поиск
Список
Период
Сортировка
От Pavel Stehule
Тема Re: Converting BYTEA from/to BIGINT
Дата
Msg-id AANLkTi=Mt84tQaBGB_qwH1-51ABQLnUgLMsZFfcZ9yCg@mail.gmail.com
обсуждение исходный текст
Ответ на Converting BYTEA from/to BIGINT  (Vincenzo Romano <vincenzo.romano@notorand.it>)
Ответы Re: Converting BYTEA from/to BIGINT  (Vincenzo Romano <vincenzo.romano@notorand.it>)
Список pgsql-general
Hello

you can try

postgres=# select int8send(256);
      int8send
--------------------
 \x0000000000000100
(1 row)

for converting from bytea to int8 you need a custom function - probably in C :(

Pavel


2010/7/26 Vincenzo Romano <vincenzo.romano@notorand.it>:
> Hi all.
>
> I'd like to convert an 8-bytes BYTEA into a BIGINT and possibly vice versa.
> Is there any way to do it?
>
> --
> Vincenzo Romano
> NotOrAnd Information Technologies
> NON QVIETIS MARIBVS NAVTA PERITVS
>
> --
> Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-general
>

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

Предыдущее
От: Vincenzo Romano
Дата:
Сообщение: Converting BYTEA from/to BIGINT
Следующее
От: "Machiel Richards"
Дата:
Сообщение: Re: Data dumps to files - best methods?