Re: Use %u to print user mapping's umid and userid

From: Etsuro Fujita <fujita(dot)etsuro(at)lab(dot)ntt(dot)co(dot)jp>
To: Ashutosh Bapat <ashutosh(dot)bapat(at)enterprisedb(dot)com>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Use %u to print user mapping's umid and userid
Date: 2016-04-28 11:59:49
Message-ID: 5721FB35.6040803@lab.ntt.co.jp
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 2016/03/14 17:56, Ashutosh Bapat wrote:
> On Mon, Mar 14, 2016 at 1:29 PM, Etsuro Fujita
> <fujita(dot)etsuro(at)lab(dot)ntt(dot)co(dot)jp <mailto:fujita(dot)etsuro(at)lab(dot)ntt(dot)co(dot)jp>> wrote:

> /*
> * Build the fdw_private list that will be available to the
> executor.
> * Items in the list must match order in enum FdwScanPrivateIndex.
> */
> fdw_private = list_make4(makeString(sql.data),
> retrieved_attrs,
> makeInteger(fpinfo->fetch_size),
> makeInteger(foreignrel->umid));
>
> I don't think it's correct to use makeInteger for the foreignrel's umid.

> As long as we are using makeInteger() and inVal() pair to set and
> extract the values, it should be fine.

Yeah, but my concern about this is eg, print plan if debugging (ie,
debug_print_plan=on); the umid OID will be printed with the %ld
specifier, so in some platform, the OID might be printed wrongly. Maybe
I'm missing something, though.

Sorry for the long delay.

Best regards,
Etsuro Fujita

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Michael Paquier 2016-04-28 12:10:58 Re: [PATCH] amroutine->amsupport from numeric to defined constants
Previous Message Bruce Momjian 2016-04-28 11:56:30 Re: Sync timezone code with upstream release tzcode2016c