The following bug has been logged online:
Bug reference: 2779
Logged by: Sven Klemm
Email address: sven(at)c3d2(dot)de
PostgreSQL version: 8.1
Operating system: Linux (Debian)
Description: Making an inherited table to a view causes could not
open relation error in base table
Details:
Steps to reproduce:
CREATE TABLE base( name TEXT );
CREATE TABLE child() INHERITS( base );
CREATE RULE "_RETURN" AS ON SELECT TO child DO INSTEAD SELECT 'Chunky
Bacon'::text AS name;
SELECT * FROM child;
SELECT * FROM ONLY base;
-- the next query causes the error
SELECT * FROM base;
After dropping child queries to base work again.