]> granicus.if.org Git - postgresql/commit
Speed up information schema privilege views
authorPeter Eisentraut <peter_e@gmx.net>
Sat, 5 Dec 2009 21:43:36 +0000 (21:43 +0000)
committerPeter Eisentraut <peter_e@gmx.net>
Sat, 5 Dec 2009 21:43:36 +0000 (21:43 +0000)
commit36f887c41c294d0035d84dfac75b4cc68a514950
tree0481aff6c13784e06286065f3b0919aeee6a9453
parent636bac6e4617caa60dbbd5a2e3f4cf7afa88281a
Speed up information schema privilege views

Instead of expensive cross joins to resolve the ACL, add table-returning
function aclexplode() that expands the ACL into a useful form, and join
against that.

Also, implement the role_*_grants views as a thin layer over the respective
*_privileges views instead of essentially repeating the same code twice.

fixes bug #4596

by Joachim Wieland, with cleanup by me
src/backend/catalog/information_schema.sql
src/backend/utils/adt/acl.c
src/include/catalog/catversion.h
src/include/catalog/pg_proc.h
src/include/utils/acl.h