Skip site navigation (1) Skip section navigation (2)

Re: 4G row table?

From: Manfred Koizar <mkoi-pg(at)aon(dot)at>
To: gry(at)ll(dot)mit(dot)edu
Cc: pgsql-performance(at)postgresql(dot)org
Subject: Re: 4G row table?
Date: 2002-12-19 19:07:53
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-performance
On Thu, 19 Dec 2002 14:10:58 -0500, george young <gry(at)ll(dot)mit(dot)edu>
>with 4 billion(4e9) rows.  I would guess to make wafer, die_row, etc. be of
>type "char", probably testtype a char too with a separate testtype lookup table.
>Even so, this will be a huge table.

Don't know if you can store 0-127 in a "char" column ... Anyway, it
doesn't matter, if it does not cause the tuple size to cross a 4 byte
boundary, because the tuple size will be rounded up to a multiple of
>Questions: How much overhead will there be in the table in addition to the
>9 bytes of data I see?

There is a page header (ca. 20 bytes) per page (8K by default).  Then
you have a tuple header and 4 bytes ItemIdData per tuple.

PG 7.2: Without NULLs a tuple header is 32 bytes, add 4 bytes for each
tuple containing at least one NULL column.

PG 7.3: 24 bytes tuple header (with and without NULLs, because you
have only 8 columns).

>How big will the primary index on the first seven columns be?

Don't know offhand.  No time now to dig it out.  Will answer tomorrow,
if nobody else jumps in ...


In response to

pgsql-performance by date

Next:From: george youngDate: 2002-12-19 19:10:58
Subject: 4G row table?
Previous:From: Josh BerkusDate: 2002-12-19 19:02:39
Subject: Re: EXISTS vs IN vs OUTER JOINS

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group