I have the following simplified testcase:
CREATE TABLE test(id serial PRIMARY KEY, data varchar); CREATE VIEW test_v AS SELECT * from test; CREATE FUNCTION