Re: [PERFORM] Very slow update statement on 40mio rows

2013-02-26 Thread Florian Schröck
Hello Merlin, thanks for the feedback, I forwarded this to my developer, this is an interesting approach. -- Best regards Florian Schröck On 02/19/2013 09:04 PM, Merlin Moncure wrote: > On Fri, Feb 15, 2013 at 9:32 AM, Florian Schröck wrote: >> Hello Kevin, >> not updating every row which do

Re: [PERFORM] Very slow update statement on 40mio rows

2013-02-19 Thread Merlin Moncure
On Fri, Feb 15, 2013 at 9:32 AM, Florian Schröck wrote: > Hello Kevin, > not updating every row which doesn't need the update solved the problem! > Your query took only 1 minute. :) > > Thank you so much for the fast response, have a great weekend! > > PS: When you switch to "TEXT" on the explain

Re: [PERFORM] Very slow update statement on 40mio rows

2013-02-15 Thread Florian Schröck
Hello Kevin, not updating every row which doesn't need the update solved the problem! Your query took only 1 minute. :) Thank you so much for the fast response, have a great weekend! PS: When you switch to "TEXT" on the explain URL you can see the final runtime which was 66 minutes with the origi

Re: [PERFORM] Very slow update statement on 40mio rows

2013-02-15 Thread Kevin Grittner
Florian Schröck wrote: > UPDATE BackupFiles >   SET nTapeNr=0, nAFIOCounter=0, nBlockCounter=0, >   cStatus='NEW'::StatusT, bOnSetBlue=false, >   bOnSetYellow=false, nLastBackupTS= '0001-01-01 00:00:00' >   WHERE cStatus='NEW' OR cStatus='WRITING' OR cStatus='ONTAPE'; > > Explain analyze:

[PERFORM] Very slow update statement on 40mio rows

2013-02-15 Thread Florian Schröck
Hi! I'm new to this mailinglist and I'm new to postgres as well. It is about our own backup software (java); we switched the DB from MySQL to postgres and we need some help. The backup database holds all files from the server in the database. On my testing platform th