Re: How to insert into 2 tables from a view?

From: David G Johnston <david(dot)g(dot)johnston(at)gmail(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: How to insert into 2 tables from a view?
Date: 2014-12-23 20:24:59
Message-ID: 1419366299399-5831898.post@n5.nabble.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

David G Johnston wrote
>
> Chris Hoover-2 wrote
>> Sorry, in my haste to get the example out, a couple of typo's where in
>> the
>> sql.
> Next time, don't quote the entire original wrong query...
>
> Anyway, you probably want to create a trigger on your view and do the
> inserts inside the trigger function.
>
> User created CREATE RULE is not usually the correct answer to a problem.
>
> David J.

Sorry, just noticed the 9.0 so my suggestion is to upgrade :)

I'm not sure how best to do this on 9.0

David J.

--
View this message in context: http://postgresql.nabble.com/How-to-insert-into-2-tables-from-a-view-tp5831876p5831898.html
Sent from the PostgreSQL - general mailing list archive at Nabble.com.

In response to

Browse pgsql-general by date

  From Date Subject
Next Message rob stone 2014-12-24 01:39:09 Re: How to insert into 2 tables from a view?
Previous Message David G Johnston 2014-12-23 20:22:18 Re: How to insert into 2 tables from a view?