Matthew Schumacher <matt.s@aptalaska.net> writes:
> After playing with various indexes and what not I simply am unable to
> make this procedure perform any better. Perhaps someone on the list can
> spot the bottleneck and reveal why this procedure isn't performing that
> well or ways to make it better.
There's not anything obviously wrong with that procedure --- all of the
updates are on primary keys, so one would expect reasonably efficient
query plans to get chosen. Perhaps it'd be worth the trouble to build
the server with profiling enabled and get a gprof trace to see where the
time is going.
regards, tom lane