pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Ricardo Valença de Assis <valenca@campusvirtual.br>
To: pgsql-admin@postgresql.org
Subject: Slow Update
Date: Wed, 9 Mar 2005 11:44:33 -0300
Message-ID: <006401c524b6$82277940$1b00280a@ugf.br> (raw)
References: <003101c52316$bd8e4f00$8c0aa8c0@rram>
	<422EDF21.4080903@tinet.org>

Hi everydoby!

    I have a table with more than 26000 rows and I need to use update a
column of this tables on all lines according with a column. So, I need to
use update 26000 times correct? I tried to use a this command:
"UPDATE database SET column1=0 WHERE column2 in (VARIABLES)", where
VARIABLES is the list separeted by commas. But the list has about 26000
entries, so I got a message of too long parameters. Is there a way to use
UPDATE pushing values from a file? Is there a way to run update more faster?
It is taking about 10 seconds for each UPDATE... Does anyone knows another
form to do this task?

Thanks

----- Original Message ----- 
From: "Daniel Rubio" <drubior@tinet.org>
To: <pgsql-admin@postgresql.org>
Sent: Wednesday, March 09, 2005 8:33 AM
Subject: Re: [ADMIN] Too many clients----A big problem for my team


> I had the same problem a few weeks ago.
>
> Was happening that our developers using Tomcat, were using connection
> pools, and stoping and restarting their aplications which causes to
> leave these connection opened and opening some new.
>
> Look in the servlet engine (or what they use) for the number of
> connections they made (in Tomcat it's a parameter), say them not to
> leave the connections opened, and not to stop and restart the java
> application when they make changes, they must restart the "engine" (it
> closes all the opened connections).
>
> It worked for me ...
>
> ganapatiram wrote:
>
> > Hi Experts,
> >
> >            I work with postgresql 8.0 version. I have a team of 14
> > developers. When all the team connects the DB i see this error very very
> > frequently which is a severe problem for me and team all the day. The
> > error is:
> >
> >
> > *Please report this exception: java.sql.SQLException: FATAL:  sorry, too
> > many clients already*
> >
> > **
> >
> > *when i do trial and error changes i see this error differently but the
> > essense of the error remains same. *
> >
> > **
> >
> > *        *I have max_connections=200 and i have 5 users for my DB. I
> > dont understand what to do in order to resolve this. Please suggest me
> > something by which i can overcome this problem. I referred few threads
> > but none of them are of my case.
> >
> >
> >
> >
> >
> > Waiting for your valuable suggestion..........
> >
> >
> >
> >
> >
> >
> >
> >
> >
> > Thanks and Regards
> >
> > Ram
> >
>
>
> -- 
> ********************************************************
> Daniel Rubio Rodríguez
> OASI (Organisme Autònom Per la Societat de la Informació)
> c/ Assalt, 12
> 43003 - Tarragona
> Tef.: 977.244.007 - Fax: 977.224.517
> e-mail: drubio a oasi.org
> ********************************************************
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org




view thread (3+ messages)  latest in thread

Message-ID: <006401c524b6$82277940$1b00280a@ugf.br>
Permalink:  ../006401c524b6$82277940$1b00280a@ugf.br/
Also on:    postgresql.org/message-id/006401c524b6$82277940$1b00280a@ugf.br

 · 

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: valenca@campusvirtual.br
  Subject: Re: Slow Update
  In-Reply-To: <006401c524b6$82277940$1b00280a@ugf.br>
  References: <003101c52316$bd8e4f00$8c0aa8c0@rram> <422EDF21.4080903@tinet.org> <006401c524b6$82277940$1b00280a@ugf.br>

* 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