Re: CopyFrom() has become way too complicated

From: Corey Huinker <corey(dot)huinker(at)gmail(dot)com>
To: andres(at)anarazel(dot)de
Cc: pgsql-hackers(at)postgresql(dot)org, peter_e(at)gmx(dot)net
Subject: Re: CopyFrom() has become way too complicated
Date: 2018-10-15 17:41:33
Message-ID: CADkLM=evWUdD7G=_demV1JgBuYUYkmsszjtw6c0Oq0_hSJqV=g@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

>
> I think the code needs to be split up so that CopyFrom() in the loop
> body calls CopyFromOneTuple(), which then also splits out the tuple
> routing into its own CopyFromOneTupleRoute() function (that's 200 LOC on
> its own...). I suspect it'd also be good to refactor the
> partition-change code out into its own function.
>

+1
I had a hard time with this when doing my copy_srf() misadventure.

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2018-10-15 18:48:24 Re: Index-only scan returns incorrect results when using a composite GIST index with a gist_trgm_ops column.
Previous Message James Coleman 2018-10-15 17:30:47 Re: Error handling expectations