Re: storing binary data

Поиск
Список
Период
Сортировка
От Alex Pilosov
Тема Re: storing binary data
Дата
Msg-id Pine.BSO.4.10.10110231314220.25573-100000@spider.pilosoft.com
обсуждение исходный текст
Ответ на storing binary data  ("Jason Orendorff" <jason@jorendorff.com>)
Список pgsql-hackers
Use bytea. Search archives.

On Sun, 21 Oct 2001, Jason Orendorff wrote:

> Reply-To: sender
> 
> Hi.  I was surprised to discover today that postgres's
> character types don't support zero bytes.  That is,
> Postgres isn't 8-bit clean.  Why is that?
> 
> More to the point, I need to store about 1k bytes per row
> of varying-length 8-bit binary data.  I have a few options:
> 
>  + BLOBs.  PostgreSQL BLOBs make me nervous.  I worry about
>    the BLOB not being deleted when the corresponding row in
>    the table is deleted.  The documentation is vague.
> 
>  + What I really need is a binary *short* object type.
>    I have heard rumors of a legendary "bytea" type that might
>    help me, but it doesn't appear to be documented anywhere,
>    so I hesitate to use it.
> 
>  + I can base64-encode the data and store it in a "text"
>    field.  But postgres is a great big data-storage system;
>    surely it can store binary data without resorting to
>    this kind of hack.
> 
> What should I do?  Please help.  Thanks!
> 
> 



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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: CREATE OR REPLACE VIEW/TRIGGER
Следующее
От: Peter Eisentraut
Дата:
Сообщение: Re: [GENERAL] To Postgres Devs : Wouldn't changing the select limit