pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Joshua D. Drake <jd@commandprompt.com>
To: Heikki Linnakangas <heikki@enterprisedb.com>
Cc: pgsql-sql <pgsql-sql@postgresql.org>
Cc: postgresql performance list <pgsql-performance@postgresql.org>
Subject: Re: Performance on writable views
Date: Sat, 11 Aug 2007 06:58:41 -0700
Message-ID: <46BDC091.4090109@commandprompt.com> (raw)
In-Reply-To: <46BD687E.1040100@enterprisedb.com>
References: <20070808124054.GC27936@nibiru.local>
	<46BD687E.1040100@enterprisedb.com>

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Heikki Linnakangas wrote:
> Enrico Weigelt wrote:
>> I'm often using writable views as interfaces to clients, so 
>> they only see "virtual" objects and never have to cope with
>> the actual storage, ie. to give some client an totally 
>> denormalized view of certain things, containing only those 
>> information required for certain kind of operations. 

>> Now I've got the strange feeling that this makes updates
>> slow, since it always has to run the whole view query to
>> fetch an record to be updated (ie. to get OLD.*).
> 
> There is some overhead in rewriting the query, but it shouldn't be
> significantly slower than issuing the statements behind the view
> directly. I wouldn't worry about it, unless you have concrete evidence
> that it's causing problems.

I don't know about that, at least when using rules for partitioning the
impact can be significant in comparison to triggers.

It may make sense for him to push this stuff to stored procs instead.

Joshua D. Drake



- --

      === The PostgreSQL Company: Command Prompt, Inc. ===
Sales/Support: +1.503.667.4564   24x7/Emergency: +1.800.492.2240
PostgreSQL solutions since 1997  http://www.commandprompt.com/
			UNIQUE NOT NULL
Donate to the PostgreSQL Project: http://www.postgresql.org/about/donate
PostgreSQL Replication: http://www.commandprompt.com/products/

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFGvcCRATb/zqfZUUQRAqngAKCKZG1LkeBd6/Qyghv/GzPBp4qCGACfS1Ar
tXJSi/ynIQlAkATIv2yKd7M=
=lYbI
-----END PGP SIGNATURE-----



view thread (4+ messages)  latest in thread

Message-ID: <46BDC091.4090109@commandprompt.com>
Permalink:  ../46BDC091.4090109@commandprompt.com/
Also on:    postgresql.org/message-id/46BDC091.4090109@commandprompt.com

 · 

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-sql@postgresql.org
  Cc: jd@commandprompt.com, heikki@enterprisedb.com, pgsql-performance@postgresql.org
  Subject: Re: Performance on writable views
  In-Reply-To: <46BDC091.4090109@commandprompt.com>

* 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