pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Christopher Browne <cbbrowne@acm.org>
To: pgsql-admin@postgresql.org
Subject: Re: pg_restore and transaction id wraparound
Date: Fri, 28 Nov 2003 17:08:48 -0500
Message-ID: <m38ym0tabz.fsf@wolfe.cbbrowne.com> (raw)
References: <20031128211125.1938.qmail@web21407.mail.yahoo.com>

Quoth oneway_111@yahoo.com (ow):
> Hypothetical situation: a table containing, say, 10 billion rows is backed up
> and then restored with pg_restore. Would this lead to the transaction id
> wraparound issue since 10B rows are imported in one "batch"?

No.

Copying the 10 billion rows in only consumes one xid.

- If you're in "autocommit mode," then each SQL statement consumes one
  xid.

- If you type in BEGIN;, then you could have 10 billion SQL
  statements after that, and they would, altogether, consume 1 xid.  
-- 
"aa454","@","freenet.carleton.ca"
http://www3.sympatico.ca/cbbrowne/sgml.html
To iterate is human; to recurse, divine.



view thread (6+ messages)  latest in thread

Message-ID: <m38ym0tabz.fsf@wolfe.cbbrowne.com>
Permalink:  ../m38ym0tabz.fsf@wolfe.cbbrowne.com/
Also on:    postgresql.org/message-id/m38ym0tabz.fsf@wolfe.cbbrowne.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-admin@postgresql.org
  Cc: cbbrowne@acm.org
  Subject: Re: pg_restore and transaction id wraparound
  In-Reply-To: <m38ym0tabz.fsf@wolfe.cbbrowne.com>
  References: <20031128211125.1938.qmail@web21407.mail.yahoo.com> <m38ym0tabz.fsf@wolfe.cbbrowne.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox