Chapter 17. Schema permission

Table of Contents

Tables in permission
Functions in permission

Below are the tables, views and functions for permission

Tables in permission

grp_penalty_threshold

  • id serial PRIMARY KEY
  • grp integer UNIQUE #1 NOT NULL REFERENCES permission.table.grp-tree
  • org_unit integer UNIQUE #1 NOT NULL REFERENCES actor.table.org-unit
  • penalty integer UNIQUE #1 NOT NULL REFERENCES config.table.standing-penalty
  • threshold numeric(8,2) NOT NULL

grp_perm_map

  • id serial PRIMARY KEY
  • grp integer UNIQUE #1 NOT NULL REFERENCES permission.table.grp-tree
  • perm integer UNIQUE #1 NOT NULL REFERENCES permission.table.perm-list
  • depth integer NOT NULL
  • grantable boolean NOT NULL DEFAULT false

grp_tree

  • id serial PRIMARY KEY
  • name text UNIQUE NOT NULL
  • parent integer REFERENCES permission.table.grp-tree
  • usergroup boolean NOT NULL DEFAULT true
  • perm_interval interval NOT NULL DEFAULT '3 years'::interval
  • description text
  • application_perm text
  • hold_priority integer NOT NULL

Indexes on grp_tree

  • grp_tree_parent_idx parent

Tables referencing via foreign key constraints

perm_list

  • id serial PRIMARY KEY
  • code text UNIQUE NOT NULL
  • description text

Indexes on perm_list

  • perm_list_code_idx code

Tables referencing via foreign key constraints

temp_perm

  • id integer PRIMARY KEY
  • code text UNIQUE
  • description text
  • old_id integer
  • predefined boolean NOT NULL DEFAULT true

usr_grp_map

  • id serial PRIMARY KEY
  • usr integer UNIQUE #1 NOT NULL REFERENCES actor.table.usr
  • grp integer UNIQUE #1 NOT NULL REFERENCES permission.table.grp-tree

usr_object_perm_map

  • id serial PRIMARY KEY
  • usr integer UNIQUE #1 NOT NULL REFERENCES actor.table.usr
  • perm integer UNIQUE #1 NOT NULL REFERENCES permission.table.perm-list
  • object_type text UNIQUE #1 NOT NULL
  • object_id text UNIQUE #1 NOT NULL
  • grantable boolean NOT NULL DEFAULT false

Indexes on usr_object_perm_map

  • uopm_usr_idx usr

usr_perm_map

  • id serial PRIMARY KEY
  • usr integer UNIQUE #1 NOT NULL REFERENCES actor.table.usr
  • perm integer UNIQUE #1 NOT NULL REFERENCES permission.table.perm-list
  • depth integer NOT NULL
  • grantable boolean NOT NULL DEFAULT false

usr_work_ou_map

  • id serial PRIMARY KEY
  • usr integer UNIQUE #1 NOT NULL REFERENCES actor.table.usr
  • work_ou integer UNIQUE #1 NOT NULL REFERENCES actor.table.org-unit