Re: Idle in transaction

From: John <jfabiani(at)yolo(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: Idle in transaction
Date: 2009-07-17 14:44:59
Message-ID: 200907170744.59361.jfabiani@yolo.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Friday 17 July 2009 07:17:15 am Sharma, Sid wrote:
> Sorry. Forgot to mention the postgres version
>
> PostgreSQL 8.1.3 on i686-pc-linux-gnu, compiled by GCC 2.96
>
>
>
> ________________________________
>
> From: Sharma, Sid
> Sent: Friday, July 17, 2009 10:05 AM
> To: pgsql-general(at)postgresql(dot)org
> Subject: Idle in transaction
>
>
>
> Hi
>
> I'm a postgres newbie. I just implemented a new web application using
> postgres.
>
> When I look at the db connections (via ps), I notice that all existing
> connections are in 'Idle in Transaction' state.
>
> They never go to idle state.
>
> The application itself remains functional and responsive. It has been up
> for over 36 hours now without any issues.
>
> What is the significance of this state? Does this imply a transaction
> leak? Then why am I not noticing deadlocks, timeouts etc.
>
> Thanks
>
> Sid

In my case it was caused by a select statement that I neither issued a commit
or rollback. So you have started a transaction without closing it somewhere
in your app. My app continued to work without apparent issue. The only
thing I noticed was pgAdmin3 could not make changes to the data structure
without closing my app.

So somewhere in your code you have started a transaction without closing it.

Johnf

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Craig Ringer 2009-07-17 14:48:19 Re: Asking for assistance in determining storage requirements
Previous Message Bill Moran 2009-07-17 14:43:51 Re: Idle in transaction