Views created by UNION ALL

From: Tatsuo Ishii <ishii(at)postgresql(dot)org>
To: pgsql-hackers(at)postgresql(dot)org
Subject: Views created by UNION ALL
Date: 2015-08-13 09:03:50
Message-ID: 20150813.180350.974486523759490903.t-ishii@sraoss.co.jp
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Views created by UNION ALL could be updated with both UPDATE and
DELETE operations. They are just transformed to UPDATE/DELETE
operation on base tables (or views). I think INSERT cannot be accepted
however. For example, suppose we have v1:

CREATE VIEW v1 AS SELECT * FROM t1 UNION ALL SELECT * FROM t2;

Inserting into v1 is ambiguous because it can be transformed either
inserting into t1 or t2.

So I think we could make v1 auto updatable view.

Best regards,
--
Tatsuo Ishii
SRA OSS, Inc. Japan
English: http://www.sraoss.co.jp/index_en.php
Japanese:http://www.sraoss.co.jp

Browse pgsql-hackers by date

  From Date Subject
Next Message Taiki Kondo 2015-08-13 09:29:34 [Proposal] Table partition + join pushdown
Previous Message Pavel Stehule 2015-08-13 08:01:53 Re: count_nulls(VARIADIC "any")