Re: COPY enhancements - Mailing list pgsql-hackers

From Emmanuel Cecchet
Subject Re: COPY enhancements
Date
Msg-id 4ACBF7E3.3090306@frogthinker.org
Whole thread Raw
In response to Re: COPY enhancements  (Josh Berkus <josh@agliodbs.com>)
List pgsql-hackers
<div class="moz-text-plain" graphical-quote="true" lang="x-unicode" style="font-family: -moz-fixed; font-size: 13px;"
wrap="true"><prewrap="">I just realized that I forgot to CC the list when I answered to Josh... resending!
 

Josh,

</pre><blockquote type="cite"><blockquote type="cite"><pre wrap=""><span class="moz-txt-citetags">>> </span>I
thinkthat this was the original idea but we should probably rollback
 
<span class="moz-txt-citetags">>> </span>the error logging if the command has been rolled back. It might be more
<span class="moz-txt-citetags">>> </span>consistent to use the same hi_options as the copy command. Any idea
what
<span class="moz-txt-citetags">>> </span>would be best?
<span class="moz-txt-citetags">>> </span>       </pre></blockquote><pre wrap=""><span
class="moz-txt-citetags">></span>
<span class="moz-txt-citetags">> </span>Well, if we're logging to a file, you wouldn't be <b
class="moz-txt-star"><spanclass="moz-txt-tag">*</span>able<span class="moz-txt-tag">*</span></b> to roll them
 
<span class="moz-txt-citetags">> </span>back.  Also, presumbly, if you abort a COPY because of errors, you
<span class="moz-txt-citetags">> </span>probably want to keep the errors around for later analysis.  No?
<span class="moz-txt-citetags">> </span>   </pre></blockquote><pre wrap="">You are right about the file (though this
functionalityis not 
 
implemented yet).
I don't have any strong opinion about the right behavior if COPY aborts. 
The error log table would contain tuples that were not inserted anyway. 
Now knowing whether the bad tuples come from a successful COPY command 
or not will be left to the user.

Emmanuel
<div class="moz-txt-sig">-- 
Emmanuel Cecchet
Aster Data Systems
Web: <a class="moz-txt-link-freetext" href="http://www.asterdata.com">http://www.asterdata.com</a>


</div></pre></div>

pgsql-hackers by date:

Previous
From: KaiGai Kohei
Date:
Subject: Re: [PATCH] DefaultACLs
Next
From: Itagaki Takahiro
Date:
Subject: Re: Encoding issues in console and eventlog on win32