pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
database physical storage
2+ messages / 2 participants
[nested] [flat]

* database physical storage
@ 2006-06-15 04:56  Praveen Kumar N <praveen_n@students.iiit.net>
  0 siblings, 1 reply; 2+ messages in thread

From: Praveen Kumar N @ 2006-06-15 04:56 UTC (permalink / raw)
  To: pgsql-admin

hai...

 	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.

thanks in anticipation

regards,
-- 
  N Praveen Kumar

 	Imagination is more important than knowledge...
                                 --Albert Einstein




^ permalink  raw  reply  [nested|flat] 2+ messages in thread

* Re: database physical storage
@ 2006-06-15 13:11  Michael Fuhr <mike@fuhr.org>
  parent: Praveen Kumar N <praveen_n@students.iiit.net>
  0 siblings, 0 replies; 2+ messages in thread

From: Michael Fuhr @ 2006-06-15 13:11 UTC (permalink / raw)
  To: Praveen Kumar N <praveen_n@students.iiit.net>; +Cc: 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



^ permalink  raw  reply  [nested|flat] 2+ messages in thread


end of thread, other threads:[~2006-06-15 13:11 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2006-06-15 04:56 database physical storage Praveen Kumar N <praveen_n@students.iiit.net>
2006-06-15 13:11 ` Michael Fuhr <mike@fuhr.org>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox