Re: Fwd: Before triggers and usage in partitioned tables

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Sergio Ramazzina <sramazzina(at)gmail(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Fwd: Before triggers and usage in partitioned tables
Date: 2010-03-23 16:41:42
Message-ID: 1044.1269362502@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Sergio Ramazzina <sramazzina(at)gmail(dot)com> writes:
> [ test case ]

It seems to work as expected for me:

regression=# insert into tpm_wind_dcn values ('r','i','2010-01-09',42);
INSERT 0 0
regression=# select * from tpm_wind_dcn;
router | interface | data | qora | m1 | m2 | m3 | m4 | m5 | m6
--------+-----------+------------+------+----+----+----+----+----+----
r | i | 2010-01-09 | 42 | | | | | |
(1 row)

regression=# select * from only tpm_wind_dcn;
router | interface | data | qora | m1 | m2 | m3 | m4 | m5 | m6
--------+-----------+------+------+----+----+----+----+----+----
(0 rows)

regression=# select * from tp_wind_dcn_day9;
router | interface | data | qora | m1 | m2 | m3 | m4 | m5 | m6
--------+-----------+------------+------+----+----+----+----+----+----
r | i | 2010-01-09 | 42 | | | | | |
(1 row)

I wonder whether you are confused about how inheritance works. Rows
that are in child tables are supposed to show up when the parent is
read (as in my first SELECT above), except when you specify ONLY
(as in my second SELECT).

regards, tom lane

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Dean Rasheed 2010-03-23 19:15:07 Re: Help me with this multi-table query
Previous Message Ben Chobot 2010-03-23 16:25:49 [SPAM] Re: pgreplay log file replayer released