From: | "Jim C(dot) Nasby" <jnasby(at)pervasive(dot)com> |
---|---|
To: | "Leif B(dot) Kristensen" <leif(at)solumslekt(dot)org> |
Cc: | pgsql-general(at)postgresql(dot)org |
Subject: | Re: psql is slow and it does not take much resources |
Date: | 2006-05-04 21:06:51 |
Message-ID: | 20060504210650.GL97354@pervasive.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
On Thu, May 04, 2006 at 10:58:24PM +0200, Leif B. Kristensen wrote:
> On Thursday 04 May 2006 22:30, Jim C. Nasby wrote:
> >On Wed, May 03, 2006 at 04:28:10PM +0200, Leif B. Kristensen wrote:
> >> However, I'm wondering if there's a practical limit to how many rows
> >> you can insert within one transaction?
> >
> >I believe transactions are limited to 4B commands, so the answer would
> >be 4B rows.
>
> That is definitely not the case. I routinely do around 36000 inserts
> wrapped up in one transaction.
Check your eyes or cleen your monitor. ;) I said 4B as in 4 *billion*.
And as Tom mentioned, if you have foreign keys or triggers each insert
will burn through multiple CIDs.
> I know that there is one hard-wired limit due to the OID wrap-around
> problem, at 2^31 commands in one transaction. But the practical limit
> due to hardware resources is probably much lower.
This has nothing to do with OIDs, and in fact I don't believe there's
any intrinsic reason why you couldn't insert more than 2B records in a
table with OIDs so long as you don't have a unique index defined on it.
--
Jim C. Nasby, Sr. Engineering Consultant jnasby(at)pervasive(dot)com
Pervasive Software http://pervasive.com work: 512-231-6117
vcard: http://jim.nasby.net/pervasive.vcf cell: 512-569-9461
From | Date | Subject | |
---|---|---|---|
Next Message | Scott Marlowe | 2006-05-04 21:12:34 | Re: psql is slow and it does not take much resources |
Previous Message | Jim C. Nasby | 2006-05-04 21:03:46 | Re: Is PostgreSQL an easy choice for a large CMS? |