Re: The fastest way to update thousands of rows in moderately sized table

From: twoflower <standa(dot)kurik(at)gmail(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: The fastest way to update thousands of rows in moderately sized table
Date: 2015-07-24 08:18:44
Message-ID: 1437725924621-5859203.post@n5.nabble.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Thank you, I will look into those suggestions.

Meanwhile, I started experimenting with partitioning the table into smaller
tables, each holding rows with ID spanning 1 million values and using this
approach, the UPDATE takes 300ms. I have to check if all the SELECTs I am
issuing against the original table keep their performance, but so far it
seems they do, if the appropriate indexes are present on the child tables. I
was worried about the overhead of each query having to go through all
(currently) 58 partition tables, but it seems like it's not that big of a
deal.

--
View this message in context: http://postgresql.nabble.com/The-fastest-way-to-update-thousands-of-rows-in-moderately-sized-table-tp5859144p5859203.html
Sent from the PostgreSQL - general mailing list archive at Nabble.com.

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message 林士博 2015-07-24 08:29:24 Re: Re: The fastest way to update thousands of rows in moderately sized table
Previous Message 林士博 2015-07-24 08:04:10 Re: Re: The fastest way to update thousands of rows in moderately sized table