Size of Partition Table in PostgreSQL 9.0
Published on Apr 27, 2011
In PostgreSQL, every table is an object, using pg_relation_size(‘object_name’) will give the size of the object. If you send the partition table in the place of ‘object_name’, it gives only that object size but not the sizes of child tables. Check out the example given below. postgres=# \dt+ List of relations Schema | Name | Type | Owner | Size | Description --------+---------------+-------+----------+------------+------------- public | child1 | table | postgres | 8192 bytes | public | child2 | table | postgres | 8192 bytes | public | parent | table | postgres | 0 bytes | (3 rows) pg_relation_size() on parent table will not give the exact size.
Continue reading →