Re: [GENERAL] Search then Delete Performance

2010-09-15 Thread Michael Hull
hael Hull >> Cc: pgsql-general@postgresql.org >> Subject: Re: [GENERAL] Search then Delete Performance >> >>   On 09/14/10 5:55 PM, Michael Hull wrote: >> > So fairly simply, I have a daemon running on a machine, which >> accesses >> > this DB. Clients connect an

Re: [GENERAL] Search then Delete Performance

2010-09-14 Thread Dann Corbit
> -Original Message- > From: pgsql-general-ow...@postgresql.org [mailto:pgsql-general- > ow...@postgresql.org] On Behalf Of John R Pierce > Sent: Tuesday, September 14, 2010 8:41 PM > To: Michael Hull > Cc: pgsql-general@postgresql.org > Subject: Re: [GENERA

Re: [GENERAL] Search then Delete Performance

2010-09-14 Thread John R Pierce
On 09/14/10 5:55 PM, Michael Hull wrote: So fairly simply, I have a daemon running on a machine, which accesses this DB. Clients connect and request the details for say 1000 simulations, at which point the daemon takes 1000 entries from the unassigned table and moves them to the assigned table.

Re: [GENERAL] Search then Delete Performance

2010-09-14 Thread Tom Lane
Michael Hull writes: > I am fairly new to practical databases, but I am trying out the c > interface to postgres and am wondering how to improve performance. I > am a researcher, and I am trying to perform a large parameter sweep. > Since this will involve a couple of thousand simulations, I have

Re: [GENERAL] Search then Delete Performance

2010-09-14 Thread Arjen Nienhuis
Hi, It's probably slow because you run many queries where a few would work: DELETE FROM unassignedjobs WHERE jobid IN (6, 8 ,2, 99, 66) But I wouldn't know how to build a query like that in C. A script in python or even bash that dit it would be faster than your C implementation. What you can d

[GENERAL] Search then Delete Performance

2010-09-14 Thread Michael Hull
Hi Everyone, I am fairly new to practical databases, but I am trying out the c interface to postgres and am wondering how to improve performance. I am a researcher, and I am trying to perform a large parameter sweep. Since this will involve a couple of thousand simulations, I have a process that ma