explain.depesz.com

PostgreSQL's explain analyze made readable

Result: VPQa

Settings
# exclusive inclusive rows x rows loops node
1. 3.110 756.697 ↑ 1.0 1 1

Result (cost=567,636.75..567,636.76 rows=1 width=40) (actual time=756.697..756.697 rows=1 loops=1)

2.          

CTE matches

3. 0.022 0.118 ↑ 1.0 27 1

Hash Join (cost=14.62..20.19 rows=27 width=46) (actual time=0.097..0.118 rows=27 loops=1)

  • Hash Cond: (media_1.id = media.id)
4. 0.017 0.017 ↑ 1.0 94 1

Seq Scan on media media_1 (cost=0.00..4.94 rows=94 width=16) (actual time=0.010..0.017 rows=94 loops=1)

5. 0.007 0.079 ↑ 1.0 27 1

Hash (cost=14.29..14.29 rows=27 width=62) (actual time=0.079..0.079 rows=27 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 11kB
6. 0.030 0.072 ↑ 1.0 27 1

Hash Join (cost=9.09..14.29 rows=27 width=62) (actual time=0.039..0.072 rows=27 loops=1)

  • Hash Cond: (media.id = user_media_offline.media_id)
7. 0.012 0.012 ↑ 1.0 94 1

Seq Scan on media (cost=0.00..4.94 rows=94 width=46) (actual time=0.001..0.012 rows=94 loops=1)

8. 0.008 0.030 ↑ 1.0 27 1

Hash (cost=8.75..8.75 rows=27 width=16) (actual time=0.030..0.030 rows=27 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 10kB
9. 0.022 0.022 ↑ 1.0 27 1

Index Only Scan using user_media_offline_pkey on user_media_offline (cost=0.28..8.75 rows=27 width=16) (actual time=0.018..0.022 rows=27 loops=1)

  • Index Cond: (user_id = '3b634574-260d-4d74-880d-075c1be5a8cf'::uuid)
  • Heap Fetches: 0
10.          

CTE view

11. 0.046 0.049 ↑ 1.0 27 1

Sort (cost=1.18..1.25 rows=27 width=48) (actual time=0.039..0.049 rows=27 loops=1)

  • Sort Key: matches.name, matches.id
  • Sort Method: quicksort Memory: 27kB
12. 0.003 0.003 ↑ 1.0 27 1

CTE Scan on matches (cost=0.00..0.54 rows=27 width=48) (actual time=0.000..0.003 rows=27 loops=1)

13.          

Initplan (forResult)

14. 0.005 0.134 ↑ 1.0 1 1

Aggregate (cost=0.61..0.62 rows=1 width=8) (actual time=0.134..0.134 rows=1 loops=1)

15. 0.129 0.129 ↑ 1.0 27 1

CTE Scan on matches matches_1 (cost=0.00..0.54 rows=27 width=0) (actual time=0.100..0.129 rows=27 loops=1)

16. 176.485 753.453 ↑ 1.0 1 1

Aggregate (cost=567,614.69..567,614.70 rows=1 width=32) (actual time=753.452..753.453 rows=1 loops=1)

17. 0.041 576.968 ↑ 1.0 27 1

Nested Loop Left Join (cost=20,994.21..567,614.62 rows=27 width=80) (actual time=81.971..576.968 rows=27 loops=1)

18. 0.072 0.072 ↑ 1.0 27 1

CTE Scan on view (cost=0.00..0.54 rows=27 width=48) (actual time=0.039..0.072 rows=27 loops=1)

19. 137.754 576.855 ↑ 1.0 1 27

Nested Loop Left Join (cost=20,994.21..21,022.73 rows=1 width=48) (actual time=21.353..21.365 rows=1 loops=27)

20. 6.804 439.101 ↑ 1.0 1 27

Nested Loop Left Join (cost=18,866.18..18,894.17 rows=1 width=502) (actual time=16.252..16.263 rows=1 loops=27)

21. 5.454 432.297 ↑ 1.0 1 27

Nested Loop Left Join (cost=18,795.51..18,823.46 rows=1 width=470) (actual time=16.000..16.011 rows=1 loops=27)

22. 6.615 426.843 ↑ 1.0 1 27

Nested Loop Left Join (cost=18,585.29..18,613.22 rows=1 width=438) (actual time=15.798..15.809 rows=1 loops=27)

23. 374.517 420.228 ↑ 1.0 1 27

Nested Loop Left Join (cost=18,318.67..18,346.57 rows=1 width=406) (actual time=15.553..15.564 rows=1 loops=27)

24. 0.081 45.711 ↑ 1.0 1 27

Nested Loop Left Join (cost=3,544.44..3,572.30 rows=1 width=374) (actual time=1.682..1.693 rows=1 loops=27)

25. 0.054 5.157 ↑ 1.0 1 27

Nested Loop Left Join (cost=1,696.04..1,723.88 rows=1 width=342) (actual time=0.181..0.191 rows=1 loops=27)

26. 0.054 3.429 ↑ 1.0 1 27

Nested Loop Left Join (cost=851.35..870.09 rows=1 width=326) (actual time=0.121..0.127 rows=1 loops=27)

27. 0.054 1.323 ↑ 1.0 1 27

Nested Loop Left Join (cost=6.66..9.16 rows=1 width=310) (actual time=0.046..0.049 rows=1 loops=27)

28. 0.027 0.621 ↑ 1.0 1 27

Nested Loop Left Join (cost=0.85..3.32 rows=1 width=274) (actual time=0.022..0.023 rows=1 loops=27)

29. 0.054 0.432 ↑ 1.0 1 27

Nested Loop Left Join (cost=0.57..1.79 rows=1 width=254) (actual time=0.014..0.016 rows=1 loops=27)

30. 0.054 0.351 ↑ 1.0 1 27

Nested Loop Left Join (cost=0.43..1.55 rows=1 width=238) (actual time=0.011..0.013 rows=1 loops=27)

31. 0.081 0.270 ↑ 1.0 1 27

Nested Loop (cost=0.29..1.30 rows=1 width=206) (actual time=0.008..0.010 rows=1 loops=27)

32. 0.162 0.162 ↑ 1.0 1 27

Index Scan using media_pkey on media vm (cost=0.14..1.05 rows=1 width=190) (actual time=0.005..0.006 rows=1 loops=27)

  • Index Cond: (id = view.id)
  • Filter: (state <> 'DELETED'::text)
33. 0.027 0.027 ↑ 1.0 1 27

Index Only Scan using media_pkey on media media_2 (cost=0.14..0.25 rows=1 width=16) (actual time=0.001..0.001 rows=1 loops=27)

  • Index Cond: (id = vm.id)
  • Heap Fetches: 0
34. 0.027 0.027 ↑ 1.0 1 27

Index Only Scan using media_pkey on media media_3 (cost=0.14..0.25 rows=1 width=48) (actual time=0.001..0.001 rows=1 loops=27)

  • Index Cond: (id = media_2.id)
  • Heap Fetches: 0
35. 0.027 0.027 ↑ 1.0 1 27

Index Only Scan using media_pkey on media media_4 (cost=0.14..0.25 rows=1 width=48) (actual time=0.001..0.001 rows=1 loops=27)

  • Index Cond: (id = media_2.id)
  • Heap Fetches: 0
36. 0.162 0.162 ↑ 1.0 1 27

Index Scan using user_media_offline_pkey on user_media_offline user_media_offline_1 (cost=0.28..1.45 rows=1 width=20) (actual time=0.006..0.006 rows=1 loops=27)

  • Index Cond: ((user_id = '3b634574-260d-4d74-880d-075c1be5a8cf'::uuid) AND (media_id = vm.id))
37. 0.054 0.648 ↑ 1.0 1 27

Limit (cost=5.81..5.81 rows=1 width=52) (actual time=0.022..0.024 rows=1 loops=27)

38. 0.135 0.594 ↑ 2.0 1 27

Sort (cost=5.81..5.81 rows=2 width=52) (actual time=0.021..0.022 rows=1 loops=27)

  • Sort Key: media_version.version DESC
  • Sort Method: quicksort Memory: 25kB
39. 0.459 0.459 ↑ 1.0 2 27

Seq Scan on media_version (cost=0.00..5.80 rows=2 width=52) (actual time=0.007..0.017 rows=2 loops=27)

  • Filter: (media_id = vm.id)
  • Rows Removed by Filter: 142
40. 0.108 2.052 ↑ 1.0 1 27

Nested Loop Left Join (cost=844.69..860.93 rows=1 width=48) (actual time=0.074..0.076 rows=1 loops=27)

41. 0.027 0.405 ↑ 1.0 1 27

Nested Loop Left Join (cost=0.97..16.48 rows=1 width=87) (actual time=0.014..0.015 rows=1 loops=27)

42. 0.054 0.270 ↑ 1.0 1 27

Nested Loop Left Join (cost=0.55..8.70 rows=1 width=87) (actual time=0.009..0.010 rows=1 loops=27)

43. 0.135 0.135 ↑ 1.0 1 27

Index Scan using pk_document on document (cost=0.28..8.29 rows=1 width=87) (actual time=0.004..0.005 rows=1 loops=27)

  • Index Cond: (media_version.media_document_id = id)
44. 0.081 0.081 ↑ 1.0 1 27

Index Scan using pk_user on sec_user (cost=0.27..0.41 rows=1 width=32) (actual time=0.003..0.003 rows=1 loops=27)

  • Index Cond: (id = document.owner_id)
  • Filter: (state <> 'DELETED'::text)
45. 0.108 0.108 ↑ 1.0 1 27

Index Scan using pk_person on person (cost=0.42..7.78 rows=1 width=16) (actual time=0.004..0.004 rows=1 loops=27)

  • Index Cond: (id = sec_user.person_id)
  • Filter: (state <> 'DELETED'::text)
46. 0.248 1.539 ↑ 1.0 1 27

Nested Loop Left Join (cost=843.72..844.19 rows=1 width=48) (actual time=0.055..0.057 rows=1 loops=27)

47. 0.015 1.107 ↑ 1.0 1 27

Nested Loop Left Join (cost=774.43..774.62 rows=1 width=107) (actual time=0.040..0.041 rows=1 loops=27)

48. 0.049 0.540 ↑ 1.0 1 27

Nested Loop Left Join (cost=763.47..763.62 rows=1 width=75) (actual time=0.019..0.020 rows=1 loops=27)

49. 0.054 0.054 ↑ 1.0 1 27

Index Scan using pk_person on person person_1 (cost=0.42..0.55 rows=1 width=43) (actual time=0.002..0.002 rows=1 loops=27)

  • Index Cond: (id = person.id)
50. 0.069 0.437 ↑ 1.0 1 23

Aggregate (cost=763.05..763.06 rows=1 width=32) (actual time=0.018..0.019 rows=1 loops=23)

51. 0.023 0.368 ↓ 0.0 0 23

Nested Loop Left Join (cost=732.16..763.04 rows=1 width=272) (actual time=0.016..0.016 rows=0 loops=23)

52. 0.023 0.345 ↓ 0.0 0 23

Nested Loop Left Join (cost=711.54..742.39 rows=1 width=264) (actual time=0.015..0.015 rows=0 loops=23)

53. 0.000 0.322 ↓ 0.0 0 23

Nested Loop Left Join (cost=693.97..724.79 rows=1 width=232) (actual time=0.014..0.014 rows=0 loops=23)

54. 0.023 0.322 ↓ 0.0 0 23

Nested Loop Left Join (cost=94.64..125.43 rows=1 width=200) (actual time=0.014..0.014 rows=0 loops=23)

55. 0.000 0.299 ↓ 0.0 0 23

Nested Loop Left Join (cost=64.85..95.61 rows=1 width=168) (actual time=0.013..0.013 rows=0 loops=23)

56. 0.023 0.299 ↓ 0.0 0 23

Nested Loop (cost=12.63..43.36 rows=1 width=136) (actual time=0.013..0.013 rows=0 loops=23)

57. 0.023 0.276 ↓ 0.0 0 23

Nested Loop (cost=12.20..34.91 rows=1 width=152) (actual time=0.012..0.012 rows=0 loops=23)

58. 0.046 0.253 ↓ 0.0 0 23

Hash Right Join (cost=11.78..26.47 rows=1 width=133) (actual time=0.011..0.011 rows=0 loops=23)

  • Hash Cond: (employee_department.id = employee.department_id)
59. 0.000 0.000 ↓ 0.0 0

Seq Scan on employee_department (cost=0.00..13.40 rows=340 width=48) (never executed)

60. 0.023 0.207 ↓ 0.0 0 23

Hash (cost=11.77..11.77 rows=1 width=101) (actual time=0.009..0.009 rows=0 loops=23)

  • Buckets: 1024 Batches: 1 Memory Usage: 8kB
61. 0.069 0.184 ↓ 0.0 0 23

Hash Right Join (cost=8.45..11.77 rows=1 width=101) (actual time=0.008..0.008 rows=0 loops=23)

  • Hash Cond: (employee_function.id = employee.function_id)
62. 0.000 0.000 ↓ 0.0 0

Seq Scan on employee_function (cost=0.00..2.95 rows=95 width=33) (never executed)

63. 0.000 0.115 ↓ 0.0 0 23

Hash (cost=8.44..8.44 rows=1 width=84) (actual time=0.005..0.005 rows=0 loops=23)

  • Buckets: 1024 Batches: 1 Memory Usage: 8kB
64. 0.115 0.115 ↓ 0.0 0 23

Index Scan using employee_person_id_state_idx on employee (cost=0.42..8.44 rows=1 width=84) (actual time=0.005..0.005 rows=0 loops=23)

  • Index Cond: ((person_id = person_1.id) AND (state = 'ACTIVE'::text))
65. 0.000 0.000 ↓ 0.0 0

Index Scan using organization_id_state_idx on organization (cost=0.42..8.44 rows=1 width=35) (never executed)

  • Index Cond: (id = employee.organization_id)
66. 0.000 0.000 ↓ 0.0 0

Index Only Scan using person_id_state_idx on person person_4 (cost=0.42..8.44 rows=1 width=16) (never executed)

  • Index Cond: (id = person_1.id)
  • Heap Fetches: 0
67. 0.000 0.000 ↓ 0.0 0

Aggregate (cost=52.22..52.23 rows=1 width=32) (never executed)

68. 0.000 0.000 ↓ 0.0 0

Nested Loop (cost=13.87..52.21 rows=2 width=32) (never executed)

69. 0.000 0.000 ↓ 0.0 0

Nested Loop (cost=4.58..18.37 rows=2 width=64) (never executed)

70. 0.000 0.000 ↓ 0.0 0

Bitmap Heap Scan on employee_address (cost=4.16..9.50 rows=2 width=48) (never executed)

  • Recheck Cond: (employee_id = employee.id)
71. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on pk_employee_address (cost=0.00..4.16 rows=2 width=0) (never executed)

  • Index Cond: (employee_id = employee.id)
72. 0.000 0.000 ↓ 0.0 0

Index Only Scan using address_pkey on address address_1 (cost=0.42..4.44 rows=1 width=16) (never executed)

  • Index Cond: (id = employee_address.address_id)
  • Heap Fetches: 0
73. 0.000 0.000 ↓ 0.0 0

Nested Loop Left Join (cost=9.29..16.91 rows=1 width=48) (never executed)

  • Filter: (employee_address.address_id = address.id)
74. 0.000 0.000 ↓ 0.0 0

Index Scan using address_pkey on address (cost=0.42..0.58 rows=1 width=16) (never executed)

  • Index Cond: (id = address_1.id)
  • Filter: (state <> 'DELETED'::text)
75. 0.000 0.000 ↓ 0.0 0

Nested Loop (cost=8.87..16.32 rows=1 width=48) (never executed)

76. 0.000 0.000 ↓ 0.0 0

Hash Right Join (cost=8.45..15.87 rows=1 width=48) (never executed)

  • Hash Cond: (country.id = addr.country_id)
77. 0.000 0.000 ↓ 0.0 0

Seq Scan on country (cost=0.00..6.48 rows=248 width=28) (never executed)

78. 0.000 0.000 ↓ 0.0 0

Hash (cost=8.44..8.44 rows=1 width=209) (never executed)

79. 0.000 0.000 ↓ 0.0 0

Index Scan using address_pkey on address addr (cost=0.42..8.44 rows=1 width=209) (never executed)

  • Index Cond: (id = address.id)
  • Filter: (state <> 'DELETED'::text)
80. 0.000 0.000 ↓ 0.0 0

Index Only Scan using address_pkey on address address_2 (cost=0.42..0.45 rows=1 width=16) (never executed)

  • Index Cond: (id = addr.id)
  • Heap Fetches: 0
81. 0.000 0.000 ↓ 0.0 0

Aggregate (cost=29.80..29.81 rows=1 width=32) (never executed)

82. 0.000 0.000 ↓ 0.0 0

Nested Loop (cost=10.12..29.79 rows=1 width=32) (never executed)

83. 0.000 0.000 ↓ 0.0 0

Nested Loop (cost=0.84..12.87 rows=1 width=41) (never executed)

84. 0.000 0.000 ↓ 0.0 0

Index Scan using pk_organization_address on organization_address (cost=0.42..8.44 rows=1 width=25) (never executed)

  • Index Cond: (organization_id = employee.organization_id)
85. 0.000 0.000 ↓ 0.0 0

Index Only Scan using address_pkey on address address_4 (cost=0.42..4.44 rows=1 width=16) (never executed)

  • Index Cond: (id = organization_address.address_id)
  • Heap Fetches: 0
86. 0.000 0.000 ↓ 0.0 0

Nested Loop Left Join (cost=9.29..16.91 rows=1 width=48) (never executed)

  • Filter: (organization_address.address_id = address_3.id)
87. 0.000 0.000 ↓ 0.0 0

Index Scan using address_pkey on address address_3 (cost=0.42..0.58 rows=1 width=16) (never executed)

  • Index Cond: (id = address_4.id)
  • Filter: (state <> 'DELETED'::text)
88. 0.000 0.000 ↓ 0.0 0

Nested Loop (cost=8.87..16.32 rows=1 width=48) (never executed)

89. 0.000 0.000 ↓ 0.0 0

Hash Right Join (cost=8.45..15.87 rows=1 width=48) (never executed)

  • Hash Cond: (country_1.id = addr_1.country_id)
90. 0.000 0.000 ↓ 0.0 0

Seq Scan on country country_1 (cost=0.00..6.48 rows=248 width=28) (never executed)

91. 0.000 0.000 ↓ 0.0 0

Hash (cost=8.44..8.44 rows=1 width=209) (never executed)

92. 0.000 0.000 ↓ 0.0 0

Index Scan using address_pkey on address addr_1 (cost=0.42..8.44 rows=1 width=209) (never executed)

  • Index Cond: (id = address_3.id)
  • Filter: (state <> 'DELETED'::text)
93. 0.000 0.000 ↓ 0.0 0

Index Only Scan using address_pkey on address address_5 (cost=0.42..0.45 rows=1 width=16) (never executed)

  • Index Cond: (id = addr_1.id)
  • Heap Fetches: 0
94. 0.000 0.000 ↓ 0.0 0

Aggregate (cost=599.33..599.34 rows=1 width=32) (never executed)

95. 0.000 0.000 ↓ 0.0 0

Nested Loop Left Join (cost=0.00..599.32 rows=1 width=61) (never executed)

  • Join Filter: (employee_communication_data.communication_data_type_id = communication_data_type.id)
96. 0.000 0.000 ↓ 0.0 0

Seq Scan on employee_communication_data (cost=0.00..598.08 rows=1 width=46) (never executed)

  • Filter: (employee_id = employee.id)
97. 0.000 0.000 ↓ 0.0 0

Seq Scan on communication_data_type (cost=0.00..1.11 rows=11 width=31) (never executed)

  • Filter: employee_usable
98. 0.000 0.000 ↓ 0.0 0

Aggregate (cost=17.57..17.58 rows=1 width=32) (never executed)

99. 0.000 0.000 ↓ 0.0 0

Hash Left Join (cost=5.69..17.56 rows=3 width=65) (never executed)

  • Hash Cond: (organization_communication_data.communication_data_type_id = communication_data_type_1.id)
100. 0.000 0.000 ↓ 0.0 0

Bitmap Heap Scan on organization_communication_data (cost=4.45..16.30 rows=3 width=50) (never executed)

  • Recheck Cond: (organization_id = employee.organization_id)
101. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on organization_communication_data_organization_id_idx (cost=0.00..4.45 rows=3 width=0) (never executed)

  • Index Cond: (organization_id = employee.organization_id)
102. 0.000 0.000 ↓ 0.0 0

Hash (cost=1.11..1.11 rows=11 width=31) (never executed)

103. 0.000 0.000 ↓ 0.0 0

Seq Scan on communication_data_type communication_data_type_1 (cost=0.00..1.11 rows=11 width=31) (never executed)

  • Filter: organization_usable
104. 0.000 0.000 ↓ 0.0 0

Aggregate (cost=20.62..20.63 rows=1 width=8) (never executed)

105. 0.000 0.000 ↓ 0.0 0

Index Only Scan using employee_organization_id_state_idx on employee org_emp (cost=0.42..20.60 rows=9 width=0) (never executed)

  • Index Cond: ((organization_id = employee.organization_id) AND (state = 'ACTIVE'::text))
  • Heap Fetches: 0
106. 0.092 0.552 ↑ 1.0 1 23

Aggregate (cost=10.96..10.97 rows=1 width=32) (actual time=0.024..0.024 rows=1 loops=23)

107. 0.046 0.460 ↑ 1.0 1 23

Nested Loop Left Join (cost=8.73..10.96 rows=1 width=96) (actual time=0.019..0.020 rows=1 loops=23)

108. 0.046 0.391 ↑ 1.0 1 23

Nested Loop (cost=8.59..10.36 rows=1 width=80) (actual time=0.017..0.017 rows=1 loops=23)

109. 0.115 0.322 ↑ 1.0 1 23

Hash Join (cost=8.45..9.77 rows=1 width=80) (actual time=0.013..0.014 rows=1 loops=23)

  • Hash Cond: (person_type.id = person_to_person_type.person_type_id)
110. 0.092 0.092 ↑ 1.0 20 23

Seq Scan on person_type (cost=0.00..1.25 rows=20 width=64) (actual time=0.001..0.004 rows=20 loops=23)

  • Filter: (state <> 'DELETED'::text)
111. 0.023 0.115 ↑ 1.0 1 23

Hash (cost=8.44..8.44 rows=1 width=16) (actual time=0.005..0.005 rows=1 loops=23)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
112. 0.092 0.092 ↑ 1.0 1 23

Index Only Scan using pk_person_to_person_type on person_to_person_type (cost=0.42..8.44 rows=1 width=16) (actual time=0.004..0.004 rows=1 loops=23)

  • Index Cond: (person_id = person_1.id)
  • Heap Fetches: 0
113. 0.023 0.023 ↑ 1.0 1 23

Index Only Scan using person_type_pkey on person_type person_type_1 (cost=0.14..0.56 rows=1 width=16) (actual time=0.001..0.001 rows=1 loops=23)

  • Index Cond: (id = person_type.id)
  • Heap Fetches: 0
114. 0.023 0.023 ↑ 1.0 1 23

Index Only Scan using person_type_pkey on person_type person_type_2 (cost=0.14..0.56 rows=1 width=48) (actual time=0.001..0.001 rows=1 loops=23)

  • Index Cond: (id = person_type_1.id)
  • Heap Fetches: 0
115. 0.023 0.184 ↑ 1.0 1 23

Aggregate (cost=69.29..69.30 rows=1 width=32) (actual time=0.008..0.008 rows=1 loops=23)

116. 0.023 0.161 ↓ 0.0 0 23

Nested Loop Left Join (cost=55.85..69.28 rows=1 width=112) (actual time=0.007..0.007 rows=0 loops=23)

117. 0.000 0.138 ↓ 0.0 0 23

Nested Loop Left Join (cost=30.22..43.62 rows=1 width=80) (actual time=0.006..0.006 rows=0 loops=23)

118. 0.046 0.138 ↓ 0.0 0 23

Nested Loop (cost=4.59..17.96 rows=1 width=48) (actual time=0.006..0.006 rows=0 loops=23)

119. 0.046 0.046 ↑ 1.0 1 23

Index Only Scan using pk_person on person person_5 (cost=0.42..8.44 rows=1 width=16) (actual time=0.002..0.002 rows=1 loops=23)

  • Index Cond: (id = person_1.id)
  • Heap Fetches: 6
120. 0.023 0.046 ↓ 0.0 0 23

Bitmap Heap Scan on speaker (cost=4.16..9.51 rows=1 width=64) (actual time=0.002..0.002 rows=0 loops=23)

  • Recheck Cond: (speaker_person_id = person_1.id)
  • Filter: (state = ANY ('{ACTIVE,LIMBO}'::text[]))
121. 0.023 0.023 ↓ 0.0 0 23

Bitmap Index Scan on speaker_speaker_person_id_idx (cost=0.00..4.16 rows=2 width=0) (actual time=0.001..0.001 rows=0 loops=23)

  • Index Cond: (speaker_person_id = person_1.id)
122. 0.000 0.000 ↓ 0.0 0

Aggregate (cost=25.63..25.64 rows=1 width=32) (never executed)

123. 0.000 0.000 ↓ 0.0 0

Hash Join (cost=11.32..25.62 rows=3 width=112) (never executed)

  • Hash Cond: (indication_area.id = speaker_indication_area.indication_area_id)
124. 0.000 0.000 ↓ 0.0 0

Seq Scan on indication_area (cost=0.00..13.40 rows=340 width=112) (never executed)

125. 0.000 0.000 ↓ 0.0 0

Hash (cost=11.28..11.28 rows=3 width=16) (never executed)

126. 0.000 0.000 ↓ 0.0 0

Bitmap Heap Scan on speaker_indication_area (cost=4.17..11.28 rows=3 width=16) (never executed)

  • Recheck Cond: (speaker_id = speaker.id)
127. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on speaker_indication_area_pk (cost=0.00..4.17 rows=3 width=0) (never executed)

  • Index Cond: (speaker_id = speaker.id)
128. 0.000 0.000 ↓ 0.0 0

Aggregate (cost=25.63..25.64 rows=1 width=32) (never executed)

129. 0.000 0.000 ↓ 0.0 0

Hash Join (cost=11.32..25.62 rows=3 width=112) (never executed)

  • Hash Cond: (speaker_request_reason.id = speaker_speaker_request_reason.speaker_request_reason_id)
130. 0.000 0.000 ↓ 0.0 0

Seq Scan on speaker_request_reason (cost=0.00..13.40 rows=340 width=112) (never executed)

131. 0.000 0.000 ↓ 0.0 0

Hash (cost=11.28..11.28 rows=3 width=16) (never executed)

132. 0.000 0.000 ↓ 0.0 0

Bitmap Heap Scan on speaker_speaker_request_reason (cost=4.17..11.28 rows=3 width=16) (never executed)

  • Recheck Cond: (speaker_id = speaker.id)
133. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on speaker_speaker_request_reason_pk (cost=0.00..4.17 rows=3 width=0) (never executed)

  • Index Cond: (speaker_id = speaker.id)
134. 0.108 1.674 ↑ 1.0 1 27

Nested Loop Left Join (cost=844.69..853.78 rows=1 width=48) (actual time=0.059..0.062 rows=1 loops=27)

135. 0.054 0.324 ↑ 1.0 1 27

Nested Loop Left Join (cost=0.97..9.33 rows=1 width=87) (actual time=0.011..0.012 rows=1 loops=27)

136. 0.054 0.216 ↑ 1.0 1 27

Nested Loop Left Join (cost=0.55..1.55 rows=1 width=87) (actual time=0.007..0.008 rows=1 loops=27)

137. 0.108 0.108 ↑ 1.0 1 27

Index Scan using pk_document on document document_1 (cost=0.28..1.14 rows=1 width=87) (actual time=0.003..0.004 rows=1 loops=27)

  • Index Cond: (vm.thumbnail_document_id = id)
138. 0.054 0.054 ↑ 1.0 1 27

Index Scan using pk_user on sec_user sec_user_1 (cost=0.27..0.41 rows=1 width=32) (actual time=0.002..0.002 rows=1 loops=27)

  • Index Cond: (id = document_1.owner_id)
  • Filter: (state <> 'DELETED'::text)
139. 0.054 0.054 ↑ 1.0 1 27

Index Scan using pk_person on person person_2 (cost=0.42..7.78 rows=1 width=16) (actual time=0.002..0.002 rows=1 loops=27)

  • Index Cond: (id = sec_user_1.person_id)
  • Filter: (state <> 'DELETED'::text)
140. 0.177 1.242 ↑ 1.0 1 27

Nested Loop Left Join (cost=843.72..844.19 rows=1 width=48) (actual time=0.044..0.046 rows=1 loops=27)

141. 0.045 0.918 ↑ 1.0 1 27

Nested Loop Left Join (cost=774.43..774.62 rows=1 width=107) (actual time=0.033..0.034 rows=1 loops=27)

142. 0.042 0.432 ↑ 1.0 1 27

Nested Loop Left Join (cost=763.47..763.62 rows=1 width=75) (actual time=0.015..0.016 rows=1 loops=27)

143. 0.054 0.054 ↑ 1.0 1 27

Index Scan using pk_person on person person_3 (cost=0.42..0.55 rows=1 width=43) (actual time=0.002..0.002 rows=1 loops=27)

  • Index Cond: (id = person_2.id)
144. 0.063 0.336 ↑ 1.0 1 21

Aggregate (cost=763.05..763.06 rows=1 width=32) (actual time=0.016..0.016 rows=1 loops=21)

145. 0.000 0.273 ↓ 0.0 0 21

Nested Loop Left Join (cost=732.16..763.04 rows=1 width=272) (actual time=0.013..0.013 rows=0 loops=21)

146. 0.021 0.273 ↓ 0.0 0 21

Nested Loop Left Join (cost=711.54..742.39 rows=1 width=264) (actual time=0.013..0.013 rows=0 loops=21)

147. 0.021 0.252 ↓ 0.0 0 21

Nested Loop Left Join (cost=693.97..724.79 rows=1 width=232) (actual time=0.012..0.012 rows=0 loops=21)

148. 0.000 0.231 ↓ 0.0 0 21

Nested Loop Left Join (cost=94.64..125.43 rows=1 width=200) (actual time=0.011..0.011 rows=0 loops=21)

149. 0.021 0.231 ↓ 0.0 0 21

Nested Loop Left Join (cost=64.85..95.61 rows=1 width=168) (actual time=0.011..0.011 rows=0 loops=21)

150. 0.000 0.210 ↓ 0.0 0 21

Nested Loop (cost=12.63..43.36 rows=1 width=136) (actual time=0.010..0.010 rows=0 loops=21)

151. 0.021 0.210 ↓ 0.0 0 21

Nested Loop (cost=12.20..34.91 rows=1 width=152) (actual time=0.010..0.010 rows=0 loops=21)

152. 0.063 0.189 ↓ 0.0 0 21

Hash Right Join (cost=11.78..26.47 rows=1 width=133) (actual time=0.009..0.009 rows=0 loops=21)

  • Hash Cond: (employee_department_1.id = employee_1.department_id)
153. 0.000 0.000 ↓ 0.0 0

Seq Scan on employee_department employee_department_1 (cost=0.00..13.40 rows=340 width=48) (never executed)

154. 0.021 0.126 ↓ 0.0 0 21

Hash (cost=11.77..11.77 rows=1 width=101) (actual time=0.006..0.006 rows=0 loops=21)

  • Buckets: 1024 Batches: 1 Memory Usage: 8kB
155. 0.042 0.105 ↓ 0.0 0 21

Hash Right Join (cost=8.45..11.77 rows=1 width=101) (actual time=0.005..0.005 rows=0 loops=21)

  • Hash Cond: (employee_function_1.id = employee_1.function_id)
156. 0.000 0.000 ↓ 0.0 0

Seq Scan on employee_function employee_function_1 (cost=0.00..2.95 rows=95 width=33) (never executed)

157. 0.000 0.063 ↓ 0.0 0 21

Hash (cost=8.44..8.44 rows=1 width=84) (actual time=0.003..0.003 rows=0 loops=21)

  • Buckets: 1024 Batches: 1 Memory Usage: 8kB
158. 0.063 0.063 ↓ 0.0 0 21

Index Scan using employee_person_id_state_idx on employee employee_1 (cost=0.42..8.44 rows=1 width=84) (actual time=0.003..0.003 rows=0 loops=21)

  • Index Cond: ((person_id = person_3.id) AND (state = 'ACTIVE'::text))
159. 0.000 0.000 ↓ 0.0 0

Index Scan using organization_id_state_idx on organization organization_1 (cost=0.42..8.44 rows=1 width=35) (never executed)

  • Index Cond: (id = employee_1.organization_id)
160. 0.000 0.000 ↓ 0.0 0

Index Only Scan using person_id_state_idx on person person_6 (cost=0.42..8.44 rows=1 width=16) (never executed)

  • Index Cond: (id = person_3.id)
  • Heap Fetches: 0
161. 0.000 0.000 ↓ 0.0 0

Aggregate (cost=52.22..52.23 rows=1 width=32) (never executed)

162. 0.000 0.000 ↓ 0.0 0

Nested Loop (cost=13.87..52.21 rows=2 width=32) (never executed)

163. 0.000 0.000 ↓ 0.0 0

Nested Loop (cost=4.58..18.37 rows=2 width=64) (never executed)

164. 0.000 0.000 ↓ 0.0 0

Bitmap Heap Scan on employee_address employee_address_1 (cost=4.16..9.50 rows=2 width=48) (never executed)

  • Recheck Cond: (employee_id = employee_1.id)
165. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on pk_employee_address (cost=0.00..4.16 rows=2 width=0) (never executed)

  • Index Cond: (employee_id = employee_1.id)
166. 0.000 0.000 ↓ 0.0 0

Index Only Scan using address_pkey on address address_7 (cost=0.42..4.44 rows=1 width=16) (never executed)

  • Index Cond: (id = employee_address_1.address_id)
  • Heap Fetches: 0
167. 0.000 0.000 ↓ 0.0 0

Nested Loop Left Join (cost=9.29..16.91 rows=1 width=48) (never executed)

  • Filter: (employee_address_1.address_id = address_6.id)
168. 0.000 0.000 ↓ 0.0 0

Index Scan using address_pkey on address address_6 (cost=0.42..0.58 rows=1 width=16) (never executed)

  • Index Cond: (id = address_7.id)
  • Filter: (state <> 'DELETED'::text)
169. 0.000 0.000 ↓ 0.0 0

Nested Loop (cost=8.87..16.32 rows=1 width=48) (never executed)

170. 0.000 0.000 ↓ 0.0 0

Hash Right Join (cost=8.45..15.87 rows=1 width=48) (never executed)

  • Hash Cond: (country_2.id = addr_2.country_id)
171. 0.000 0.000 ↓ 0.0 0

Seq Scan on country country_2 (cost=0.00..6.48 rows=248 width=28) (never executed)

172. 0.000 0.000 ↓ 0.0 0

Hash (cost=8.44..8.44 rows=1 width=209) (never executed)

173. 0.000 0.000 ↓ 0.0 0

Index Scan using address_pkey on address addr_2 (cost=0.42..8.44 rows=1 width=209) (never executed)

  • Index Cond: (id = address_6.id)
  • Filter: (state <> 'DELETED'::text)
174. 0.000 0.000 ↓ 0.0 0

Index Only Scan using address_pkey on address address_8 (cost=0.42..0.45 rows=1 width=16) (never executed)

  • Index Cond: (id = addr_2.id)
  • Heap Fetches: 0
175. 0.000 0.000 ↓ 0.0 0

Aggregate (cost=29.80..29.81 rows=1 width=32) (never executed)

176. 0.000 0.000 ↓ 0.0 0

Nested Loop (cost=10.12..29.79 rows=1 width=32) (never executed)

177. 0.000 0.000 ↓ 0.0 0

Nested Loop (cost=0.84..12.87 rows=1 width=41) (never executed)

178. 0.000 0.000 ↓ 0.0 0

Index Scan using pk_organization_address on organization_address organization_address_1 (cost=0.42..8.44 rows=1 width=25) (never executed)

  • Index Cond: (organization_id = employee_1.organization_id)
179. 0.000 0.000 ↓ 0.0 0

Index Only Scan using address_pkey on address address_10 (cost=0.42..4.44 rows=1 width=16) (never executed)

  • Index Cond: (id = organization_address_1.address_id)
  • Heap Fetches: 0
180. 0.000 0.000 ↓ 0.0 0

Nested Loop Left Join (cost=9.29..16.91 rows=1 width=48) (never executed)

  • Filter: (organization_address_1.address_id = address_9.id)
181. 0.000 0.000 ↓ 0.0 0

Index Scan using address_pkey on address address_9 (cost=0.42..0.58 rows=1 width=16) (never executed)

  • Index Cond: (id = address_10.id)
  • Filter: (state <> 'DELETED'::text)
182. 0.000 0.000 ↓ 0.0 0

Nested Loop (cost=8.87..16.32 rows=1 width=48) (never executed)

183. 0.000 0.000 ↓ 0.0 0

Hash Right Join (cost=8.45..15.87 rows=1 width=48) (never executed)

  • Hash Cond: (country_3.id = addr_3.country_id)
184. 0.000 0.000 ↓ 0.0 0

Seq Scan on country country_3 (cost=0.00..6.48 rows=248 width=28) (never executed)

185. 0.000 0.000 ↓ 0.0 0

Hash (cost=8.44..8.44 rows=1 width=209) (never executed)

186. 0.000 0.000 ↓ 0.0 0

Index Scan using address_pkey on address addr_3 (cost=0.42..8.44 rows=1 width=209) (never executed)

  • Index Cond: (id = address_9.id)
  • Filter: (state <> 'DELETED'::text)
187. 0.000 0.000 ↓ 0.0 0

Index Only Scan using address_pkey on address address_11 (cost=0.42..0.45 rows=1 width=16) (never executed)

  • Index Cond: (id = addr_3.id)
  • Heap Fetches: 0
188. 0.000 0.000 ↓ 0.0 0

Aggregate (cost=599.33..599.34 rows=1 width=32) (never executed)

189. 0.000 0.000 ↓ 0.0 0

Nested Loop Left Join (cost=0.00..599.32 rows=1 width=61) (never executed)

  • Join Filter: (employee_communication_data_1.communication_data_type_id = communication_data_type_2.id)
190. 0.000 0.000 ↓ 0.0 0

Seq Scan on employee_communication_data employee_communication_data_1 (cost=0.00..598.08 rows=1 width=46) (never executed)

  • Filter: (employee_id = employee_1.id)
191. 0.000 0.000 ↓ 0.0 0

Seq Scan on communication_data_type communication_data_type_2 (cost=0.00..1.11 rows=11 width=31) (never executed)

  • Filter: employee_usable
192. 0.000 0.000 ↓ 0.0 0

Aggregate (cost=17.57..17.58 rows=1 width=32) (never executed)

193. 0.000 0.000 ↓ 0.0 0

Hash Left Join (cost=5.69..17.56 rows=3 width=65) (never executed)

  • Hash Cond: (organization_communication_data_1.communication_data_type_id = communication_data_type_3.id)
194. 0.000 0.000 ↓ 0.0 0

Bitmap Heap Scan on organization_communication_data organization_communication_data_1 (cost=4.45..16.30 rows=3 width=50) (never executed)

  • Recheck Cond: (organization_id = employee_1.organization_id)
195. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on organization_communication_data_organization_id_idx (cost=0.00..4.45 rows=3 width=0) (never executed)

  • Index Cond: (organization_id = employee_1.organization_id)
196. 0.000 0.000 ↓ 0.0 0

Hash (cost=1.11..1.11 rows=11 width=31) (never executed)

197. 0.000 0.000 ↓ 0.0 0

Seq Scan on communication_data_type communication_data_type_3 (cost=0.00..1.11 rows=11 width=31) (never executed)

  • Filter: organization_usable
198. 0.000 0.000 ↓ 0.0 0

Aggregate (cost=20.62..20.63 rows=1 width=8) (never executed)

199. 0.000 0.000 ↓ 0.0 0

Index Only Scan using employee_organization_id_state_idx on employee org_emp_1 (cost=0.42..20.60 rows=9 width=0) (never executed)

  • Index Cond: ((organization_id = employee_1.organization_id) AND (state = 'ACTIVE'::text))
  • Heap Fetches: 0
200. 0.063 0.441 ↑ 1.0 1 21

Aggregate (cost=10.96..10.97 rows=1 width=32) (actual time=0.021..0.021 rows=1 loops=21)

201. 0.021 0.378 ↑ 1.0 1 21

Nested Loop Left Join (cost=8.73..10.96 rows=1 width=96) (actual time=0.017..0.018 rows=1 loops=21)

202. 0.063 0.336 ↑ 1.0 1 21

Nested Loop (cost=8.59..10.36 rows=1 width=80) (actual time=0.015..0.016 rows=1 loops=21)

203. 0.084 0.252 ↑ 1.0 1 21

Hash Join (cost=8.45..9.77 rows=1 width=80) (actual time=0.012..0.012 rows=1 loops=21)

  • Hash Cond: (person_type_3.id = person_to_person_type_1.person_type_id)
204. 0.084 0.084 ↑ 1.0 20 21

Seq Scan on person_type person_type_3 (cost=0.00..1.25 rows=20 width=64) (actual time=0.001..0.004 rows=20 loops=21)

  • Filter: (state <> 'DELETED'::text)
205. 0.042 0.084 ↑ 1.0 1 21

Hash (cost=8.44..8.44 rows=1 width=16) (actual time=0.004..0.004 rows=1 loops=21)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
206. 0.042 0.042 ↑ 1.0 1 21

Index Only Scan using pk_person_to_person_type on person_to_person_type person_to_person_type_1 (cost=0.42..8.44 rows=1 width=16) (actual time=0.002..0.002 rows=1 loops=21)

  • Index Cond: (person_id = person_3.id)
  • Heap Fetches: 0
207. 0.021 0.021 ↑ 1.0 1 21

Index Only Scan using person_type_pkey on person_type person_type_4 (cost=0.14..0.56 rows=1 width=16) (actual time=0.001..0.001 rows=1 loops=21)

  • Index Cond: (id = person_type_3.id)
  • Heap Fetches: 0
208. 0.021 0.021 ↑ 1.0 1 21

Index Only Scan using person_type_pkey on person_type person_type_5 (cost=0.14..0.56 rows=1 width=48) (actual time=0.001..0.001 rows=1 loops=21)

  • Index Cond: (id = person_type_4.id)
  • Heap Fetches: 0
209. 0.021 0.147 ↑ 1.0 1 21

Aggregate (cost=69.29..69.30 rows=1 width=32) (actual time=0.007..0.007 rows=1 loops=21)

210. 0.000 0.126 ↓ 0.0 0 21

Nested Loop Left Join (cost=55.85..69.28 rows=1 width=112) (actual time=0.006..0.006 rows=0 loops=21)

211. 0.021 0.126 ↓ 0.0 0 21

Nested Loop Left Join (cost=30.22..43.62 rows=1 width=80) (actual time=0.006..0.006 rows=0 loops=21)

212. 0.042 0.105 ↓ 0.0 0 21

Nested Loop (cost=4.59..17.96 rows=1 width=48) (actual time=0.005..0.005 rows=0 loops=21)

213. 0.042 0.042 ↑ 1.0 1 21

Index Only Scan using pk_person on person person_7 (cost=0.42..8.44 rows=1 width=16) (actual time=0.002..0.002 rows=1 loops=21)

  • Index Cond: (id = person_3.id)
  • Heap Fetches: 5
214. 0.000 0.021 ↓ 0.0 0 21

Bitmap Heap Scan on speaker speaker_1 (cost=4.16..9.51 rows=1 width=64) (actual time=0.001..0.001 rows=0 loops=21)

  • Recheck Cond: (speaker_person_id = person_3.id)
  • Filter: (state = ANY ('{ACTIVE,LIMBO}'::text[]))
215. 0.021 0.021 ↓ 0.0 0 21

Bitmap Index Scan on speaker_speaker_person_id_idx (cost=0.00..4.16 rows=2 width=0) (actual time=0.001..0.001 rows=0 loops=21)

  • Index Cond: (speaker_person_id = person_3.id)
216. 0.000 0.000 ↓ 0.0 0

Aggregate (cost=25.63..25.64 rows=1 width=32) (never executed)

217. 0.000 0.000 ↓ 0.0 0

Hash Join (cost=11.32..25.62 rows=3 width=112) (never executed)

  • Hash Cond: (indication_area_1.id = speaker_indication_area_1.indication_area_id)
218. 0.000 0.000 ↓ 0.0 0

Seq Scan on indication_area indication_area_1 (cost=0.00..13.40 rows=340 width=112) (never executed)

219. 0.000 0.000 ↓ 0.0 0

Hash (cost=11.28..11.28 rows=3 width=16) (never executed)

220. 0.000 0.000 ↓ 0.0 0

Bitmap Heap Scan on speaker_indication_area speaker_indication_area_1 (cost=4.17..11.28 rows=3 width=16) (never executed)

  • Recheck Cond: (speaker_id = speaker_1.id)
221. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on speaker_indication_area_pk (cost=0.00..4.17 rows=3 width=0) (never executed)

  • Index Cond: (speaker_id = speaker_1.id)
222. 0.000 0.000 ↓ 0.0 0

Aggregate (cost=25.63..25.64 rows=1 width=32) (never executed)

223. 0.000 0.000 ↓ 0.0 0

Hash Join (cost=11.32..25.62 rows=3 width=112) (never executed)

  • Hash Cond: (speaker_request_reason_1.id = speaker_speaker_request_reason_1.speaker_request_reason_id)
224. 0.000 0.000 ↓ 0.0 0

Seq Scan on speaker_request_reason speaker_request_reason_1 (cost=0.00..13.40 rows=340 width=112) (never executed)

225. 0.000 0.000 ↓ 0.0 0

Hash (cost=11.28..11.28 rows=3 width=16) (never executed)

226. 0.000 0.000 ↓ 0.0 0

Bitmap Heap Scan on speaker_speaker_request_reason speaker_speaker_request_reason_1 (cost=4.17..11.28 rows=3 width=16) (never executed)

  • Recheck Cond: (speaker_id = speaker_1.id)
227. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on speaker_speaker_request_reason_pk (cost=0.00..4.17 rows=3 width=0) (never executed)

  • Index Cond: (speaker_id = speaker_1.id)
228. 0.324 40.473 ↑ 1.0 1 27

Aggregate (cost=1,848.39..1,848.40 rows=1 width=32) (actual time=1.499..1.499 rows=1 loops=27)

229. 0.116 40.149 ↑ 1.5 2 27

Nested Loop Left Join (cost=615.34..1,848.38 rows=3 width=51) (actual time=0.768..1.487 rows=2 loops=27)

230. 0.135 0.378 ↑ 1.5 2 27

Hash Join (cost=4.36..5.61 rows=3 width=35) (actual time=0.012..0.014 rows=2 loops=27)

  • Hash Cond: (topic.id = media_topic.topic_id)
231. 0.108 0.108 ↑ 1.0 16 27

Seq Scan on topic (cost=0.00..1.20 rows=16 width=35) (actual time=0.002..0.004 rows=16 loops=27)

  • Filter: (state <> 'DELETED'::text)
232. 0.027 0.135 ↑ 1.5 2 27

Hash (cost=4.32..4.32 rows=3 width=16) (actual time=0.005..0.005 rows=2 loops=27)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
233. 0.108 0.108 ↑ 1.5 2 27

Index Only Scan using media_topic_pkey on media_topic (cost=0.27..4.32 rows=3 width=16) (actual time=0.004..0.004 rows=2 loops=27)

  • Index Cond: (media_id = vm.id)
  • Heap Fetches: 0
234. 0.660 39.655 ↑ 1.0 1 55

Nested Loop Left Join (cost=610.98..614.25 rows=1 width=48) (actual time=0.720..0.721 rows=1 loops=55)

235. 0.165 0.165 ↑ 1.0 1 55

Index Scan using topic_pkey on topic t (cost=0.14..0.90 rows=1 width=47) (actual time=0.002..0.003 rows=1 loops=55)

  • Index Cond: (id = topic.id)
  • Filter: (state <> 'DELETED'::text)
236. 1.320 38.830 ↑ 1.0 1 55

Aggregate (cost=610.85..610.86 rows=1 width=32) (actual time=0.706..0.706 rows=1 loops=55)

237. 0.880 37.510 ↓ 1.7 12 55

Nested Loop (cost=83.06..610.83 rows=7 width=52) (actual time=0.072..0.682 rows=12 loops=55)

  • Join Filter: (activity_type.id = activity_type_1.id)
  • Rows Removed by Join Filter: 66
238. 0.660 36.630 ↓ 1.7 12 55

Nested Loop Left Join (cost=83.06..608.47 rows=7 width=84) (actual time=0.070..0.666 rows=12 loops=55)

239. 0.371 0.990 ↓ 1.7 12 55

Hash Join (cost=1.31..3.94 rows=7 width=52) (actual time=0.005..0.018 rows=12 loops=55)

  • Hash Cond: (topic_activity_type.activity_type_id = activity_type.id)
240. 0.605 0.605 ↓ 1.5 12 55

Seq Scan on topic_activity_type (cost=0.00..2.60 rows=8 width=16) (actual time=0.003..0.011 rows=12 loops=55)

  • Filter: (topic_id = t.id)
  • Rows Removed by Filter: 116
241. 0.006 0.014 ↓ 1.1 13 1

Hash (cost=1.16..1.16 rows=12 width=36) (actual time=0.014..0.014 rows=13 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
242. 0.008 0.008 ↓ 1.1 13 1

Seq Scan on activity_type (cost=0.00..1.16 rows=12 width=36) (actual time=0.005..0.008 rows=13 loops=1)

  • Filter: (state <> 'DELETED'::text)
243. 0.660 34.980 ↑ 1.0 1 660

Nested Loop Left Join (cost=81.75..86.35 rows=1 width=48) (actual time=0.050..0.053 rows=1 loops=660)

244. 0.660 32.340 ↑ 1.0 1 660

Nested Loop Left Join (cost=48.46..53.02 rows=1 width=269) (actual time=0.046..0.049 rows=1 loops=660)

245. 0.660 17.820 ↑ 1.0 1 660

Nested Loop Left Join (cost=19.04..23.58 rows=1 width=237) (actual time=0.024..0.027 rows=1 loops=660)

246. 0.660 15.180 ↑ 1.0 1 660

Nested Loop Left Join (cost=9.53..14.03 rows=1 width=205) (actual time=0.020..0.023 rows=1 loops=660)

247. 0.660 8.580 ↑ 1.0 1 660

Nested Loop Left Join (cost=7.87..12.35 rows=1 width=173) (actual time=0.011..0.013 rows=1 loops=660)

  • Join Filter: (touch_point_group.id = touch_point_group_1.id)
  • Rows Removed by Join Filter: 4
248. 0.660 5.940 ↑ 1.0 1 660

Nested Loop Left Join (cost=0.54..4.85 rows=1 width=157) (actual time=0.009..0.009 rows=1 loops=660)

  • Join Filter: (touch_point_group.id = at.touch_point_group_id)
  • Rows Removed by Join Filter: 2
249. 0.660 4.620 ↑ 1.0 1 660

Nested Loop Left Join (cost=0.54..3.73 rows=1 width=157) (actual time=0.006..0.007 rows=1 loops=660)

250. 0.000 3.300 ↑ 1.0 1 660

Nested Loop Left Join (cost=0.41..2.87 rows=1 width=141) (actual time=0.005..0.005 rows=1 loops=660)

251. 0.660 2.640 ↑ 1.0 1 660

Nested Loop (cost=0.27..2.01 rows=1 width=109) (actual time=0.003..0.004 rows=1 loops=660)

252. 1.320 1.320 ↑ 1.0 1 660

Index Scan using activity_type_pkey on activity_type at (cost=0.14..1.15 rows=1 width=93) (actual time=0.001..0.002 rows=1 loops=660)

  • Index Cond: (id = activity_type.id)
253. 0.660 0.660 ↑ 1.0 1 660

Index Only Scan using activity_type_pkey on activity_type activity_type_2 (cost=0.14..0.77 rows=1 width=16) (actual time=0.001..0.001 rows=1 loops=660)

  • Index Cond: (id = at.id)
  • Heap Fetches: 660
254. 0.660 0.660 ↑ 1.0 1 660

Index Only Scan using activity_type_pkey on activity_type activity_type_3 (cost=0.14..0.77 rows=1 width=48) (actual time=0.001..0.001 rows=1 loops=660)

  • Index Cond: (id = activity_type_2.id)
  • Heap Fetches: 660
255. 0.660 0.660 ↑ 1.0 1 660

Index Only Scan using activity_type_pkey on activity_type activity_type_4 (cost=0.14..0.77 rows=1 width=48) (actual time=0.001..0.001 rows=1 loops=660)

  • Index Cond: (id = activity_type_2.id)
  • Heap Fetches: 660
256. 0.660 0.660 ↑ 2.5 2 660

Seq Scan on touch_point_group (cost=0.00..1.06 rows=5 width=16) (actual time=0.001..0.001 rows=2 loops=660)

  • Filter: (state <> 'DELETED'::text)
257. 1.980 1.980 ↑ 1.0 5 660

Group (cost=7.33..7.38 rows=5 width=52) (actual time=0.001..0.003 rows=5 loops=660)

  • Group Key: touch_point_group_1.id, (array_length(COALESCE(array_agg(activity_type_5.id), '{}'::uuid[]), 1))
258. 0.000 0.000 ↑ 1.0 5 660

Sort (cost=7.33..7.35 rows=5 width=34) (actual time=0.000..0.000 rows=5 loops=660)

  • Sort Key: touch_point_group_1.id, (array_length(COALESCE(array_agg(activity_type_5.id), '{}'::uuid[]), 1))
  • Sort Method: quicksort Memory: 25kB
259. 0.001 0.028 ↑ 1.0 5 1

Nested Loop Left Join (cost=1.21..7.27 rows=5 width=34) (actual time=0.014..0.028 rows=5 loops=1)

260. 0.002 0.002 ↑ 1.0 5 1

Seq Scan on touch_point_group touch_point_group_1 (cost=0.00..1.06 rows=5 width=30) (actual time=0.001..0.002 rows=5 loops=1)

  • Filter: (state <> 'DELETED'::text)
261. 0.015 0.025 ↑ 1.0 1 5

Aggregate (cost=1.21..1.22 rows=1 width=4) (actual time=0.004..0.005 rows=1 loops=5)

262. 0.010 0.010 ↑ 2.5 2 5

Seq Scan on activity_type activity_type_5 (cost=0.00..1.20 rows=5 width=16) (actual time=0.002..0.002 rows=2 loops=5)

  • Filter: ((touch_point_group_id = touch_point_group_1.id) AND (state = 'ACTIVE'::text))
  • Rows Removed by Filter: 11
263. 4.620 5.940 ↑ 1.0 1 660

Aggregate (cost=1.65..1.66 rows=1 width=32) (actual time=0.009..0.009 rows=1 loops=660)

264. 1.320 1.320 ↑ 1.0 1 660

Seq Scan on activity_type_rule (cost=0.00..1.15 rows=1 width=53) (actual time=0.001..0.002 rows=1 loops=660)

  • Filter: (activity_type_id = at.id)
  • Rows Removed by Filter: 12
265. 1.320 1.980 ↑ 1.0 1 660

Aggregate (cost=9.51..9.52 rows=1 width=32) (actual time=0.003..0.003 rows=1 loops=660)

266. 0.000 0.660 ↓ 0.0 0 660

Bitmap Heap Scan on activity_type_dispatch_type (cost=4.16..9.50 rows=2 width=32) (actual time=0.001..0.001 rows=0 loops=660)

  • Recheck Cond: (activity_type_id = at.id)
267. 0.660 0.660 ↓ 0.0 0 660

Bitmap Index Scan on pk_activity_type_dispatch_type (cost=0.00..4.16 rows=2 width=0) (actual time=0.001..0.001 rows=0 loops=660)

  • Index Cond: (activity_type_id = at.id)
268. 1.980 13.860 ↑ 1.0 1 660

Aggregate (cost=29.42..29.43 rows=1 width=32) (actual time=0.021..0.021 rows=1 loops=660)

269. 0.000 11.880 ↑ 1.0 1 660

Nested Loop Left Join (cost=19.81..29.41 rows=1 width=94) (actual time=0.016..0.018 rows=1 loops=660)

270. 0.660 9.240 ↑ 1.0 1 660

Nested Loop Left Join (cost=16.68..26.25 rows=1 width=62) (actual time=0.012..0.014 rows=1 loops=660)

271. 0.660 3.300 ↑ 1.0 1 660

Nested Loop (cost=0.27..9.49 rows=1 width=46) (actual time=0.004..0.005 rows=1 loops=660)

272. 1.320 1.320 ↑ 1.0 1 660

Seq Scan on activity_type_assignment (cost=0.00..1.16 rows=1 width=33) (actual time=0.001..0.002 rows=1 loops=660)

  • Filter: (activity_type_id = at.id)
  • Rows Removed by Filter: 12
273. 1.320 1.320 ↑ 1.0 1 660

Index Scan using idx_organizational_unit_materialized_path_btree_idx on organizational_unit (cost=0.27..8.29 rows=1 width=29) (actual time=0.002..0.002 rows=1 loops=660)

  • Index Cond: (id = activity_type_assignment.organizational_unit_id)
  • Filter: (state <> 'DELETED'::text)
274. 0.660 5.280 ↑ 1.0 1 660

Nested Loop Left Join (cost=16.41..16.75 rows=1 width=48) (actual time=0.007..0.008 rows=1 loops=660)

275. 0.660 3.960 ↑ 1.0 1 660

Nested Loop (cost=0.53..0.84 rows=1 width=164) (actual time=0.005..0.006 rows=1 loops=660)

276. 0.660 2.640 ↑ 1.0 1 660

Nested Loop (cost=0.40..0.64 rows=1 width=145) (actual time=0.004..0.004 rows=1 loops=660)

277. 1.320 1.320 ↑ 1.0 1 660

Index Scan using pk_organizational_unit on organizational_unit ou (cost=0.27..0.46 rows=1 width=161) (actual time=0.002..0.002 rows=1 loops=660)

  • Index Cond: (id = organizational_unit.id)
  • Filter: (state <> 'DELETED'::text)
278. 0.660 0.660 ↑ 1.0 1 660

Index Scan using pk_organizational_hierarchy on organizational_hierarchy (cost=0.12..0.17 rows=1 width=16) (actual time=0.001..0.001 rows=1 loops=660)

  • Index Cond: (id = ou.organizational_hierarchy_id)
  • Filter: (state = 'ACTIVE'::text)
279. 0.660 0.660 ↑ 1.0 1 660

Index Scan using pk_organizational_unit_type on organizational_unit_type (cost=0.13..0.18 rows=1 width=35) (actual time=0.001..0.001 rows=1 loops=660)

  • Index Cond: (id = ou.organizational_unit_type_id)
  • Filter: (state = 'ACTIVE'::text)
280. 0.660 0.660 ↑ 1.0 1 660

Aggregate (cost=15.88..15.89 rows=1 width=32) (actual time=0.001..0.001 rows=1 loops=660)

281. 0.000 0.000 ↓ 0.0 0 660

Seq Scan on organizational_unit_tag (cost=0.00..15.88 rows=2 width=32) (actual time=0.000..0.000 rows=0 loops=660)

  • Filter: (organizational_unit_id = ou.id)
282. 1.320 2.640 ↑ 1.0 1 660

Aggregate (cost=3.13..3.14 rows=1 width=32) (actual time=0.004..0.004 rows=1 loops=660)

283. 0.605 1.320 ↓ 0.0 0 660

Nested Loop (cost=0.00..3.12 rows=1 width=71) (actual time=0.002..0.002 rows=0 loops=660)

  • Join Filter: (consent_item.consent_type_id = consent_type.id)
  • Rows Removed by Join Filter: 0
284. 0.000 0.660 ↓ 0.0 0 660

Nested Loop (cost=0.00..2.08 rows=1 width=45) (actual time=0.001..0.001 rows=0 loops=660)

  • Join Filter: (activity_type_assignment_consent_item.consent_item_id = consent_item.id)
285. 0.660 0.660 ↓ 0.0 0 660

Seq Scan on activity_type_assignment_consent_item (cost=0.00..1.01 rows=1 width=16) (actual time=0.001..0.001 rows=0 loops=660)

  • Filter: (activity_type_assignment_id = activity_type_assignment.id)
  • Rows Removed by Filter: 1
286. 0.055 0.055 ↑ 3.0 1 55

Seq Scan on consent_item (cost=0.00..1.03 rows=3 width=45) (actual time=0.001..0.001 rows=1 loops=55)

287. 0.055 0.055 ↑ 1.0 2 55

Seq Scan on consent_type (cost=0.00..1.02 rows=2 width=42) (actual time=0.001..0.001 rows=2 loops=55)

288. 1.320 1.980 ↑ 1.0 1 660

Aggregate (cost=33.30..33.31 rows=1 width=32) (actual time=0.002..0.003 rows=1 loops=660)

289. 0.000 0.660 ↓ 0.0 0 660

Nested Loop Left Join (cost=12.05..33.29 rows=1 width=36) (actual time=0.001..0.001 rows=0 loops=660)

290. 0.660 0.660 ↓ 0.0 0 660

Nested Loop (cost=11.46..26.17 rows=1 width=20) (actual time=0.001..0.001 rows=0 loops=660)

291. 0.000 0.000 ↓ 0.0 0 660

Hash Join (cost=11.32..25.11 rows=3 width=36) (actual time=0.000..0.000 rows=0 loops=660)

  • Hash Cond: (comment_type_1.id = activity_type_comment_type.comment_type_id)
292. 0.000 0.000 ↓ 0.0 0 660

Seq Scan on comment_type comment_type_1 (cost=0.00..13.00 rows=300 width=16) (actual time=0.000..0.000 rows=0 loops=660)

293. 0.000 0.000 ↓ 0.0 0

Hash (cost=11.28..11.28 rows=3 width=20) (never executed)