"Sort (cost=2505335.87..2505335.87 rows=1 width=210)" " Sort Key: res.id_" " -> Nested Loop (cost=4.93..2505335.86 rows=1 width=210)" " Join Filter: ((res.proc_def_id_)::text = (proc_.id_)::text)" " -> Nested Loop (cost=4.93..2505329.00 rows=1 width=181)" " Join Filter: ((act.call_proc_inst_id_)::text = (res.id_)::text)" " -> Seq Scan on act_hi_procinst res (cost=0.00..3186.94 rows=42594 width=106)" " -> Materialize (cost=4.93..2494475.17 rows=12 width=112)" " -> Nested Loop Left Join (cost=4.93..2494475.11 rows=12 width=112)" " Join Filter: ((self.proc_def_key_)::text = (act.proc_def_key_)::text)" " Filter: (((act.proc_def_key_ IS NOT NULL) AND (self.proc_def_key_ IS NOT NULL)) OR (act.proc_def_key_ IS NULL))" " -> Bitmap Heap Scan on act_hi_actinst act (cost=4.52..51.84 rows=12 width=126)" " Recheck Cond: ((proc_inst_id_)::text = 'cf7c46bd-ef02-11e6-9044-0aa2e56f42b1'::text)" " -> Bitmap Index Scan on act_idx_hi_act_inst_procinst (cost=0.00..4.51 rows=12 width=0)" " Index Cond: ((proc_inst_id_)::text = 'cf7c46bd-ef02-11e6-9044-0aa2e56f42b1'::text)" " -> Materialize (cost=0.41..2494423.09 rows=1 width=13)" " -> Unique (cost=0.41..2494423.07 rows=1 width=13)" " -> Index Only Scan using act_idx_hi_pro_inst_proc_def_key on act_hi_procinst self (cost=0.41..2494422.54 rows=213 width=13)" " Filter: ((SubPlan 9) = 1)" " SubPlan 9" " -> Result (cost=58.48..58.50 rows=1 width=0)" " InitPlan 2 (returns $2)" " -> Index Scan using act_uniq_auth_user on act_ru_authorization a_1 (cost=0.28..8.31 rows=1 width=0)" " Index Cond: ((type_ = 1) AND ((user_id_)::text = 'jakob.freund@camunda.com'::text) AND (resource_type_ = 6) AND ((resource_id_)::text = '*'::text))" " Filter: ((perms_ & 4096) = 4096)" " InitPlan 8 (returns $8)" " -> Result (cost=41.85..41.86 rows=1 width=0)" " InitPlan 4 (returns $4)" " -> Index Scan using act_uniq_auth_group on act_ru_authorization a_3 (cost=0.28..12.61 rows=1 width=0)" " Index Cond: ((type_ = 1) AND ((group_id_)::text = ANY ('{management,sales}'::text[])) AND (resource_type_ = 6) AND ((resource_id_)::text = '*'::text))" " Filter: ((perms_ & 4096) = 4096)" " InitPlan 7 (returns $7)" " -> Result (cost=16.62..16.63 rows=1 width=0)" " InitPlan 6 (returns $6)" " -> Index Scan using act_uniq_auth_group on act_ru_authorization a_5 (cost=0.28..8.31 rows=1 width=0)" " Index Cond: ((type_ = 0) AND (resource_type_ = 6) AND ((resource_id_)::text = '*'::text))" " Filter: (((user_id_)::text = '*'::text) AND ((perms_ & 4096) = 4096))" " SubPlan 5" " -> Index Scan using act_uniq_auth_group on act_ru_authorization a_4 (cost=0.28..8.31 rows=1 width=36)" " Index Cond: ((type_ = 0) AND (resource_type_ = 6) AND ((resource_id_)::text = (self.proc_def_key_)::text))" " Filter: (((user_id_)::text = '*'::text) AND ((perms_ & 4096) = 4096))" " SubPlan 3" " -> Index Scan using act_uniq_auth_group on act_ru_authorization a_2 (cost=0.28..12.61 rows=1 width=36)" " Index Cond: ((type_ = 1) AND ((group_id_)::text = ANY ('{management,sales}'::text[])) AND (resource_type_ = 6) AND ((resource_id_)::text = (self.proc_def_key_)::text))" " Filter: ((perms_ & 4096) = 4096)" " SubPlan 1" " -> Index Scan using act_uniq_auth_user on act_ru_authorization a (cost=0.28..8.31 rows=1 width=36)" " Index Cond: ((type_ = 1) AND ((user_id_)::text = ''::text) AND (resource_type_ = 6) AND ((resource_id_)::text = (self.proc_def_key_)::text))" " Filter: ((perms_ & 4096) = 4096)" " -> Seq Scan on act_re_procdef proc_ (cost=0.00..5.27 rows=127 width=82)"