Re: Partitioning option for COPY - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Partitioning option for COPY
Date
Msg-id 17544.1258423103@sss.pgh.pa.us
Whole thread Raw
In response to Re: Partitioning option for COPY  (Jan Urbański <wulczer@wulczer.org>)
Responses Re: Partitioning option for COPY
Re: Partitioning option for COPY
List pgsql-hackers
Jan Urbański <wulczer@wulczer.org> writes:
> Program received signal SIGSEGV, Segmentation fault.
> 0x0819368b in route_tuple_to_child (parent_relation=0xb5d93040,
> tuple=0x873b08c, hi_options=0, parentResultRelInfo=0x871e204) at copy.c:1821
> 1821                            child_relation_id =
> child_oid_cell->oid_value;
> (gdb) p child_oid_cell
> $1 = (OidCell *) 0x7f7f7f7f

This looks like the patch is trying to create a data structure in a
memory context that's not sufficiently long-lived for the use of the
structure.  If you do this in a non-cassert build, it will seem to
work, some of the time, if the memory in question happens to not
get reallocated to something else.

A good rule of thumb is to never do code development in a non-cassert
build.  You're just setting yourself up for failure.
        regards, tom lane


pgsql-hackers by date:

Previous
From: "Joshua D. Drake"
Date:
Subject: Re: next CommitFest
Next
From: Robert Haas
Date:
Subject: Re: next CommitFest