Re: TOAST not working

Поиск
Список
Период
Сортировка
От Martijn van Oosterhout
Тема Re: TOAST not working
Дата
Msg-id 20060612100703.GB3829@svana.org
обсуждение исходный текст
Ответ на Re: TOAST not working  (Angus Berry <angus.berry@elkenserve.com>)
Список pgsql-general
On Sat, Jun 10, 2006 at 10:43:02PM -0400, Angus Berry wrote:
> Ahhh... thank you. This clarifies TOAST for me. I see how TOAST applies
> to individual columns that exceed the 8k page size.
>
> Postgres specs state it's possible to have 2GB rows and up to 1,600
> columns. Can you tell me what data type would get to fill this spec. I
> wouldn't normally push to this limit, but I am expecting to have to
> defend Postgres specs. to a 3rd party.

Any variable length datatype might be able to go to 2GB. Things like
text, char, varchar and bytea are the obvious ones. Arrays too IIRC.

However, as pointed out, even a toasted field takes about 20 bytes,
which means you're limited to maybe 400 toasted fields. If you use
integers you can get to 1600.

Normally however, in cases where you need to store a lot of columns,
what you really want is an array. You could easily store an array with
a few million numerics in a single field...

Have a nice day,
--
Martijn van Oosterhout   <kleptog@svana.org>   http://svana.org/kleptog/
> From each according to his ability. To each according to his ability to litigate.

Вложения

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

Предыдущее
От: "Harald Armin Massa"
Дата:
Сообщение: Re: Best security practices for installing pgSQL with my software
Следующее
От: ptjm@interlog.com (Patrick TJ McPhee)
Дата:
Сообщение: Re: are there static variables in pgsql?