fixed-length row

Поиск
Список
Период
Сортировка
От David Garamond
Тема fixed-length row
Дата
Msg-id 4006A113.4070701@zara.6.isreserved.com
обсуждение исходный текст
Ответы Re: fixed-length row  (Richard Huxton <dev@archonet.com>)
Re: fixed-length row  (Tom Lane <tgl@sss.pgh.pa.us>)
Re: fixed-length row  (Martijn van Oosterhout <kleptog@svana.org>)
Список pgsql-general
The MySQL manual recommends that we create a "fixed-length row" if
possible, for speed (especially scanning speed). A fixed-length row is a
row which is comprised of only fixed-length fields. A fixed-length field
takes a fixed amount of bytes for storage (e.g. INT = 4 bytes, CHAR(M) =
M bytes, etc).

Is there a similar recommendation in PostgreSQL? I notice that most data
types are stored in variable-length mode anyway (is cidr and inet data
types fixed-length?)

Is there a command/query in psql which can show storage requirement for
each field? For example:

db1=# \d t1;
       Table "public.t1"
  Column |     Type    | Modifiers | Storage size
--------+-------------+-----------+--------------
  id     | inet        | not null  | 24
  i      | integer     |           | 4
  c      | varchar(10) |           | variable
Indexes:
     "t1_pkey" primary key, btree (id)

--
dave


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

Предыдущее
От: David Garamond
Дата:
Сообщение: YAGT (yet another GUID thread)
Следующее
От: Uros
Дата:
Сообщение: parse error in function