Teach RemoveRoleFromObjectPolicy() about partitioned tables.
Dean Rasheed <dean.a.rasheed@gmail.com>
Teach RemoveRoleFromObjectPolicy() about partitioned tables. Table partitioning, introduced in commit f0e44751d7, added a new relkind - RELKIND_PARTITIONED_TABLE. Update RemoveRoleFromObjectPolicy() to handle it, otherwise DROP OWNED BY will fail if the role has any RLS policies referring to partitioned tables. Dean Rasheed, reviewed by Amit Langote. Discussion: https://postgr.es/m/CAEZATCUnNOKN8sLML9jUzxecALWpEXK3a3W7y0PgFR4%2Buhgc%3Dg%40mail.gmail.com
Files
| Path | Change | +/− |
|---|---|---|
| src/backend/commands/policy.c | modified | +2 −1 |
| src/test/regress/expected/rowsecurity.out | modified | +4 −0 |
| src/test/regress/sql/rowsecurity.sql | modified | +5 −0 |
Discussion
- PG10 Partitioned tables and relation_is_updatable() 16 messages · 2017-06-11 → 2017-06-14