Re: "Healing" a table after massive updates
| От | Scott Marlowe |
|---|---|
| Тема | Re: "Healing" a table after massive updates |
| Дата | |
| Msg-id | dcc563d10809111155r27b3b3a8w9e86368ba6020b32@mail.gmail.com обсуждение исходный текст |
| Ответ на | Re: "Healing" a table after massive updates (Alan Hodgson <ahodgson@simkin.ca>) |
| Список | pgsql-general |
On Thu, Sep 11, 2008 at 11:15 AM, Alan Hodgson <ahodgson@simkin.ca> wrote: > On Thursday 11 September 2008, "Gauthier, Dave" <dave.gauthier@intel.com> > wrote: >> I have a job that loads a large table, but then has to "update" about >> half the records for various reasons. My perception of what happens on >> update for a particular recors is... >> >> - a new record will be inserted with the updated value(s). >> >> - The old record is marked as being obselete. >> > > What you might consider doing is loading the data into a temp table, > updating it there, then copying that data into the final destination. > Depending on the indexes involved, you might even find this to be faster. Especially if you can drop then recreate them on the real table before reimporting them to it.
В списке pgsql-general по дате отправления: