Re: [HACKERS] database size

From: Bruce Momjian <maillist(at)candle(dot)pha(dot)pa(dot)us>
To: scrappy(at)hub(dot)org (The Hermit Hacker)
Cc: darrenk(at)insightdist(dot)com, pgsql-hackers(at)postgreSQL(dot)org, sthomas(at)cise(dot)ufl(dot)edu
Subject: Re: [HACKERS] database size
Date: 1998-01-07 03:02:42
Message-ID: 199801070302.WAA09960@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

>
> On Tue, 6 Jan 1998, Darren King wrote:
>
> > 48 bytes + each row header (on my aix box..._your_ mileage may vary)
> > 8 bytes + two int fields @ 4 bytes each
> > 4 bytes + pointer on page to tuple
> > -------- =
> > 60 bytes per tuple
> >
> > 8192 / 60 give 136 tuples per page.
> >
> > 300000 / 136 ... round up ... need 2206 pages which gives us ...
> >
> > 2206 * 8192 = 18,071,532
> >
> > So 19 MB is about right. And this is the best to be done, unless
> > you can make do with int2s which would optimally shrink the table
> > size to 16,834,560 bytes. Any nulls in there might add a few bytes
> > per offending row too, but other than that, this should be considered
> > normal postgresql behavior.
>
> Bruce...this would be *great* to have in the FAQ!! What we do need is
> a section of the User Manual dealing with computing resources required for
> a table, similar to this :)

Added to FAQ.

--
Bruce Momjian
maillist(at)candle(dot)pha(dot)pa(dot)us

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 1998-01-07 03:10:17 Re: [COMMITTERS] 'pgsql/src/interfaces/odbc/src/socket compat.h connect.h connectp.cpp errclass.cpp errclass.h sockio.cpp sockio
Previous Message The Hermit Hacker 1998-01-07 02:37:39 Re: [COMMITTERS] 'pgsql/src/interfaces/odbc/src/socket compat.h connect.h connectp.cpp errclass.cpp errclass.h sockio.cpp sockio.h wO (fwd)