Re: How to get the 'ctid' from a record type?

From: Jim Nasby <jim(dot)nasby(at)openscg(dot)com>
To: Eric Ridge <eebbrr(at)gmail(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: How to get the 'ctid' from a record type?
Date: 2017-03-11 20:52:04
Message-ID: c9b5ef05-ead8-995b-7572-06b4f9eb6e94@openscg.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 3/10/17 10:31 PM, Eric Ridge wrote:
> What about this? Is the tuple currently being evaluated (I suppose in
> the case of a sequential scan) available in the context of a function call?

AFAIK that *very* specific case would work, because the executor would
be handing you the raw tuple. Not a great bet to make though. Also,
there should be a macro somewhere that will tell you whether you have a
full tuple or not. You'd want to make sure to check that an throw an
error if you weren't handed a full tuple.
--
Jim Nasby, Chief Data Architect, OpenSCG
http://OpenSCG.com

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Fabien COELHO 2017-03-11 21:04:53 Re: [HACKERS] Small issue in online devel documentation build
Previous Message Jim Nasby 2017-03-11 20:43:55 INSERT INTO arr2(array[1].d, array[2].d)