pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Patrick Hatcher <pathat@comcast.net>
Cc: pgsql-performance@postgresql.org <pgsql-performance@postgresql.org>
Subject: Re: Slow update statement
Date: Sat, 06 Aug 2005 10:12:43 -0400
Message-ID: <17916.1123337563@sss.pgh.pa.us> (raw)
In-Reply-To: <42F4B812.7070501@comcast.net>
References: <42F4B812.7070501@comcast.net>

Patrick Hatcher <pathat@comcast.net> writes:
> I'm running an update statement on about 12 million records using the
> following query:

> Update table_A
> set F1 = b.new_data
> from table_B b
> where b.keyfield = table_A.keyfield

What does EXPLAIN show for this?

Do you have any foreign key references to table_A from elsewhere?

			regards, tom lane



view thread (8+ messages)  latest in thread

Message-ID: <17916.1123337563@sss.pgh.pa.us>
Permalink:  ../17916.1123337563@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/17916.1123337563@sss.pgh.pa.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-performance@postgresql.org
  Cc: tgl@sss.pgh.pa.us, pathat@comcast.net
  Subject: Re: Slow update statement
  In-Reply-To: <17916.1123337563@sss.pgh.pa.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox