Skip site navigation (1) Skip section navigation (2)

Re: Update from other tables slow

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Carlo Stonebanks" <stonec(dot)register(at)sympatico(dot)ca>
Cc: pgsql-novice(at)postgresql(dot)org
Subject: Re: Update from other tables slow
Date: 2008-01-29 02:56:44
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-novice
"Carlo Stonebanks" <stonec(dot)register(at)sympatico(dot)ca> writes:
> Is there anything wrong with this UPDATE statement?

> update mdx_core.provider
> set 
>    middle_name = fix.middle_name, 
>    display_name = fix.display_name
> from mdx_import._fix_mnames as fix
> where provider.provider_id = fix.provider_id;

Who's to say?  You haven't showed us EXPLAIN data nor mentioned what
PG version you are running.

I'd ask for EXPLAIN ANALYZE, but if you aren't willing to wait for the
query to finish, that's a non-starter.  It would be good to show EXPLAIN
ANALYZE output for the variant that does finish, though.

			regards, tom lane

In response to

pgsql-novice by date

Next:From: e-letterDate: 2008-01-29 09:46:18
Subject: Re: maths functions and spreadsheet
Previous:From: Andrej Ricnik-BayDate: 2008-01-29 02:27:35
Subject: Re: maths functions and spreadsheet

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group