Re: Size of TOAST pointer

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Vignesh Raghunathan <vignesh(dot)pgsql(at)gmail(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Size of TOAST pointer
Date: 2015-07-16 22:49:58
Message-ID: 13171.1437086998@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Vignesh Raghunathan <vignesh(dot)pgsql(at)gmail(dot)com> writes:
> I was looking at the documentation for TOAST (
> http://www.postgresql.org/docs/devel/static/storage-toast.html) and it's
> specified that the toast pointer occupies 18 bytes. However, the struct
> representing the toast pointer is defined as follows
> typedef struct varatt_external

The data that actually ends up on disk is a varattrib_1b_e wrapping a
varatt_external, and that header is where the extra 2 bytes come from.

regards, tom lane

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Geoghegan 2015-07-16 23:01:20 Memory prefetching while sequentially fetching from SortTuple array, tuplestore
Previous Message Vignesh Raghunathan 2015-07-16 22:36:54 Size of TOAST pointer