From: | Andres Freund <andres(at)anarazel(dot)de> |
---|---|
To: | bucoo(at)sohu(dot)com, pgsql-bugs(at)postgresql(dot)org |
Subject: | Re: BUG #14985: ExecCopySlotTuple not set "type id" and "type mod" when from minial tuple" |
Date: | 2017-12-20 15:33:46 |
Message-ID: | 20171220153346.cxsl7nmf5372v76s@alap3.anarazel.de |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-bugs |
Hi,
On 2017-12-20 10:05:40 +0000, PG Bug reporting form wrote:
> The following bug has been logged on the website:
>
> Bug reference: 14985
> Logged by: bucoo hsiao
> Email address: bucoo(at)sohu(dot)com
> PostgreSQL version: 10.1
> Operating system: all
> Description:
This also isn't a proper bug report. If you've API questions you
shouldn't open bug reports, instead ask on the general mailing list or
such.
> HeapTuple
> ExecCopySlotTuple(TupleTableSlot *slot)
> {
> /*
> * sanity checks
> */
> Assert(slot != NULL);
> Assert(!slot->tts_isempty);
>
> /*
> * If we have a physical tuple (either format) then just copy it.
> */
> if (TTS_HAS_PHYSICAL_TUPLE(slot))
> return heap_copytuple(slot->tts_tuple);
> if (slot->tts_mintuple)
> return heap_tuple_from_minimal_tuple(slot->tts_mintuple);
> /* should be:
> if (slot->tts_mintuple)
> {
> HeapTuple result =
> heap_tuple_from_minimal_tuple(slot->tts_mintuple);
> HeapTupleHeaderSetTypeId(result->t_data,
> slot->tts_tupleDescriptor->tdtypeid);
> HeapTupleHeaderSetTypMod(result->t_data,
> slot->tts_tupleDescriptor->tdtypmod);
> return result;
> }
> */
> ...
> }
>
No, it shouldn't. It seems you're looking for ExecFetchSlotTupleDatum().
Greetings,
Andres Freund
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2017-12-20 15:37:35 | Re: BUG #14985: ExecCopySlotTuple not set "type id" and "type mod" when from minial tuple" |
Previous Message | Andres Freund | 2017-12-20 15:25:54 | Re: BUG #14984: function "heap_tuple_from_minimal_tuple" lost HeapTupleHeader->t_len value |