Re: Using multi-row technique with COPY - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Using multi-row technique with COPY
Date
Msg-id 9367.1133294199@sss.pgh.pa.us
Whole thread Raw
In response to Re: Using multi-row technique with COPY  (Bruce Momjian <pgman@candle.pha.pa.us>)
Responses Re: Using multi-row technique with COPY  (Bruce Momjian <pgman@candle.pha.pa.us>)
Re: Using multi-row technique with COPY  (Simon Riggs <simon@2ndquadrant.com>)
List pgsql-hackers
Bruce Momjian <pgman@candle.pha.pa.us> writes:
> Tom Lane wrote:
>> Something that would probably be reasonable, and require *no* weird new
>> syntax, is to shortcut in a COPY into a table created in the current
>> transaction.  I believe we still keep a flag in the relcache indicating
>> whether that's the case ...

> So if the table is created in the current transaction, we don't log? 

Log, yes, unless it's a temp table.  The point is we could avoid taking
buffer content locks.  Come to think of it, we could implement that
trivially in the heapam.c routines; it would then apply to any table
update whether generated by COPY or otherwise.

> Yes, I guess, but do we want to propogate that into pg_dump output?  I
> would think not.

Exactly my point; we don't have to change any syntax, so pg_dump
doesn't care.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: Using multi-row technique with COPY
Next
From: Bruce Momjian
Date:
Subject: Re: Using multi-row technique with COPY