From: | Michael Fuhr <mike(at)fuhr(dot)org> |
---|---|
To: | Praveen Kumar N <praveen_n(at)students(dot)iiit(dot)net> |
Cc: | pgsql-admin(at)postgresql(dot)org |
Subject: | Re: database physical storage |
Date: | 2006-06-15 13:11:51 |
Message-ID: | 20060615131151.GA3925@winnie.fuhr.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-admin |
On Thu, Jun 15, 2006 at 10:26:59AM +0530, Praveen Kumar N wrote:
> I have observed that the size of data (for example size of
> table in a database) stored by database system on physical storage is
> more than actual datasize.It seems database is storing data in some
> format.For example i have created a table with data 15MB considering each
> INTEGER of 4bytes.But after loading this data into database i have
> observed that database system is storing this table in 45MB memory.So can
> anybody tell me what is the reason to use so much memory? Is there any
> relation between actual dataset size and size of data stored on physical
> storage system.
Each row has storage overhead such as values that determine which
transactions can see the row. If rows have only a small amount of
data then the overhead is a large proportion of the storage space.
If a table has indexes then there's even more overhead. For more
information see the "Database Physical Storage" chapter in the
documentation, in particular the "Database Page Layout" section:
http://www.postgresql.org/docs/8.1/interactive/storage-page-layout.html
--
Michael Fuhr
From | Date | Subject | |
---|---|---|---|
Next Message | Benjamin Krajmalnik | 2006-06-15 17:20:03 | General question regarding sequences (Serial columns) |
Previous Message | Robin Iddon | 2006-06-15 11:20:19 | Re: autovacuum |