Re: Turning off transactions completely.

From: Martijn van Oosterhout <kleptog(at)svana(dot)org>
To: Arsalan Zaidi <azaidi(at)directi(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Turning off transactions completely.
Date: 2002-01-07 07:34:42
Message-ID: 20020107183441.A10764@svana.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Mon, Jan 07, 2002 at 11:56:12AM +0530, Arsalan Zaidi wrote:
> > Well, every statement must be within a transaction, so to reduce the
> number
> > of transactions start one explicitly and commit when you're done. Then you
> > only have one transaction for the whole thing.
> >
>
> I already do this. However, I don't want *any* transactions at all. I don't
> care if I lose data in the middle of, say an update. The nature of the app
> is such, that that data can be reconstructed.

Well, no transactions is not possible. The whole data storage system is
built around it almost. Besides, as long as everything is in one
transaction, there is *no* overhead IIRC.

> However, as it currently stands, the app takes around 30 hrs to finish it's
> run. I wish to reduce that to 24hr or less.

Wow. I can insert hundreds of rows per second within a transaction and my
hardware is not even particulatly good. That would be 21 million rows in
that time. How big is your data set? Are you using COPY or INSERT to insert
the data?

> I found a comment from 1999 where someone asked a similiar Q and Mimijian
> responded that that was not possible in pg. Is that still true? Can it be
> easily changed in the code?

I think you're working under the assumption that transactions == overhead
whereas I don't beleive that's true. Work out where the bottleneck is.
--
Martijn van Oosterhout <kleptog(at)svana(dot)org>
http://svana.org/kleptog/
> Terrorists can only take my life. Only my government can take my freedom.

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Arsalan Zaidi 2002-01-07 08:47:09 Re: Turning off transactions completely.
Previous Message Arsalan Zaidi 2002-01-07 06:26:12 Re: Turning off transactions completely.