Re: Attribute Alignment

From: "Michael Richards" <miker(at)interchange(dot)ca>
To: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Attribute Alignment
Date: 2000-12-17 20:49:40
Message-ID: 056701c0686a$e02d9680$0200a8c0@digitallis
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Is this alignment relative to the beginning of the page or tuple, or even
the tuple data area (after the tuple header)?

-Michael

> "Michael Richards" <miker(at)interchange(dot)ca> writes:
> > The alignment seems to be wrong for type CHAR(1):
>
> No, the alignment is fine. A field's align constraint says where it has
> to start, not where the next field has to start. gender starts on a
> 4-byte boundary and is 5 bytes long, then we have one byte wasted for
> alignment of yearofbirth, then yearofbirth starts on a 2-byte boundary.
> Everyone's happy.
>
> regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Mathijs Brands 2000-12-17 20:51:18 PostgreSQL crashes on me :(
Previous Message Bruce Momjian 2000-12-17 20:07:59 Manual changes for ALTER TABLE OWNER