Re: Is it good to have toast table for information schema table? - Mailing list pgsql-general

From Adrian Klaver
Subject Re: Is it good to have toast table for information schema table?
Date
Msg-id 53570C91.9000802@aklaver.com
Whole thread Raw
In response to Is it good to have toast table for information schema table?  (AI Rumman <rummandba@gmail.com>)
List pgsql-general
On 04/22/2014 04:58 PM, AI Rumman wrote:
> Hi,
>
> Is it good to have toast table for information schema table? I am using
> Postgresql 8.4 and current state is:
>
> *select datname, datfrozenxid from pg_database; *
>    datname  | datfrozenxid
> -----------+--------------
>   template1 |   1462730397
>   template0 |   1462741467
>   postgres  |   1562754912
>   jangles   |   1459615432
> (4 rows)
> *
> *
> *
> *
> *select * from pg_class  where relfrozenxid  = 1459615432;*
>      relname     | reltoastidxid | relhasindex | relfrozenxid
> ----------------+---------------+-------------+--------------
>   pg_toast_11447 |         11451 | t           |   1459615432
> (1 row)
> *
> *
> *
> *
> *select 11447::regclass; *
>              regclass
> ---------------------------------
>   information_schema.sql_features
> (1 row)
>
> Please advice.

A TOAST table is used whenever the actual table has variable length
fields that meet certain criteria:

http://www.postgresql.org/docs/9.3/static/storage-toast.html

information_schema.sql_features schema is:

test=# \d information_schema.sql_features
              Table "information_schema.sql_features"
       Column      |               Type                | Modifiers
------------------+-----------------------------------+-----------
  feature_id       | information_schema.character_data |
  feature_name     | information_schema.character_data |
  sub_feature_id   | information_schema.character_data |
  sub_feature_name | information_schema.character_data |
  is_supported     | information_schema.yes_or_no      |
  is_verified_by   | information_schema.character_data |
  comments         | information_schema.character_data |

 From here you see character_data is not fixed length:

http://www.postgresql.org/docs/9.3/static/infoschema-datatypes.html

so a TOAST table is not out of order.

I see it on my database also.

>
> Thanks.


--
Adrian Klaver
adrian.klaver@aklaver.com


pgsql-general by date:

Previous
From: AI Rumman
Date:
Subject: Is it good to have toast table for information schema table?
Next
From: xbzhang
Date:
Subject: Are there rules for add parameter in postgresql.conf?