explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 7QXg

Settings
# exclusive inclusive rows x rows loops node
1. 0.012 9.040 ↑ 501.6 44 1

Unique (cost=27,602.73..32,237.85 rows=22,072 width=2,133) (actual time=9.015..9.040 rows=44 loops=1)

2.          

Initplan (forUnique)

3. 0.012 0.012 ↑ 1.0 1 1

Seq Scan on task_mgt_tag taskmanage13_ (cost=0.00..1.79 rows=1 width=8) (actual time=0.005..0.012 rows=1 loops=1)

  • Filter: ((label)::text = 'ARCHIVED'::text)
  • Rows Removed by Filter: 62
4. 0.137 9.016 ↑ 501.6 44 1

Sort (cost=27,600.95..27,656.13 rows=22,072 width=2,133) (actual time=9.014..9.016 rows=44 loops=1)

  • Sort Key: taskentity0_.id, actions1_.business_id, comments8_.creation_date, comments2_.creation_date, actions1_.id, comments8_.id, taskmanage10_.id, taskmanage11_.id, children12_.id, comments2_.id, checklisti3_.id, taskmanage5_.id, taskmanage6_.id, (...)
  • Sort Method: quicksort Memory: 48kB
5. 0.040 8.879 ↑ 501.6 44 1

Hash Left Join (cost=4,375.72..5,638.46 rows=22,072 width=2,133) (actual time=8.811..8.879 rows=44 loops=1)

  • Hash Cond: (taskentity0_.id = tags4_.task_id)
6. 0.025 7.643 ↑ 567.9 26 1

Hash Left Join (cost=4,307.09..5,146.09 rows=14,765 width=1,884) (actual time=7.605..7.643 rows=26 loops=1)

  • Hash Cond: (taskentity0_.id = checklisti3_.task_id)
7. 0.023 7.601 ↑ 567.9 26 1

Hash Join (cost=4,305.66..5,086.42 rows=14,765 width=828) (actual time=7.574..7.601 rows=26 loops=1)

  • Hash Cond: (taskentity0_.project_business_id = project16_.business_id)
8. 2.285 7.505 ↑ 527.3 28 1

Hash Right Join (cost=4,299.94..5,025.33 rows=14,765 width=828) (actual time=7.489..7.505 rows=28 loops=1)

  • Hash Cond: (comments8_.action_id = actions1_.id)
9. 2.202 2.202 ↑ 1.0 16,490 1

Seq Scan on task_mgt_action_comment comments8_ (cost=0.00..515.90 rows=16,490 width=136) (actual time=0.004..2.202 rows=16,490 loops=1)

10. 0.028 3.018 ↑ 17.4 28 1

Hash (cost=4,293.84..4,293.84 rows=488 width=692) (actual time=3.018..3.018 rows=28 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 17kB
11. 0.027 2.990 ↑ 17.4 28 1

Hash Left Join (cost=4,262.81..4,293.84 rows=488 width=692) (actual time=2.547..2.990 rows=28 loops=1)

  • Hash Cond: (tags9_.tag_id = taskmanage10_.id)
12. 0.093 2.823 ↑ 17.4 28 1

Hash Right Join (cost=4,255.07..4,279.38 rows=488 width=539) (actual time=2.398..2.823 rows=28 loops=1)

  • Hash Cond: (actions1_.task_id = taskentity0_.id)
13. 0.293 0.416 ↓ 1.0 546 1

Hash Left Join (cost=1.14..20.69 rows=545 width=165) (actual time=0.022..0.416 rows=546 loops=1)

  • Hash Cond: (actions1_.id = tags9_.action_id)
14. 0.117 0.117 ↑ 1.0 545 1

Seq Scan on task_mgt_action actions1_ (cost=0.00..17.45 rows=545 width=149) (actual time=0.005..0.117 rows=545 loops=1)

15. 0.003 0.006 ↑ 1.0 6 1

Hash (cost=1.06..1.06 rows=6 width=16) (actual time=0.006..0.006 rows=6 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
16. 0.003 0.003 ↑ 1.0 6 1

Seq Scan on task_mgt_tag_to_action tags9_ (cost=0.00..1.06 rows=6 width=16) (actual time=0.003..0.003 rows=6 loops=1)

17. 0.016 2.314 ↑ 27.1 18 1

Hash (cost=4,247.83..4,247.83 rows=488 width=374) (actual time=2.314..2.314 rows=18 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 13kB
18. 0.023 2.298 ↑ 27.1 18 1

Hash Left Join (cost=10.13..4,247.83 rows=488 width=374) (actual time=0.364..2.298 rows=18 loops=1)

  • Hash Cond: (taskentity0_.id = comments2_.task_id)
19. 0.174 2.126 ↑ 27.1 18 1

Seq Scan on task_mgt_task taskentity0_ (cost=0.00..4,226.80 rows=488 width=249) (actual time=0.206..2.126 rows=18 loops=1)

  • Filter: (NOT (SubPlan 2))
  • Rows Removed by Filter: 958
20.          

SubPlan (forSeq Scan)

21. 1.952 1.952 ↑ 1.0 1 976

Index Only Scan using task_mgt_tag_to_task_pk on task_mgt_tag_to_task tags14_ (cost=0.28..8.29 rows=1 width=8) (actual time=0.001..0.002 rows=1 loops=976)

  • Index Cond: (task_id = taskentity0_.id)
  • Heap Fetches: 1204
22. 0.083 0.149 ↑ 1.0 228 1

Hash (cost=7.28..7.28 rows=228 width=125) (actual time=0.149..0.149 rows=228 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 45kB
23. 0.066 0.066 ↑ 1.0 228 1

Seq Scan on task_mgt_task_comment comments2_ (cost=0.00..7.28 rows=228 width=125) (actual time=0.004..0.066 rows=228 loops=1)

24. 0.026 0.140 ↑ 1.0 63 1

Hash (cost=6.96..6.96 rows=63 width=153) (actual time=0.140..0.140 rows=63 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 14kB
25. 0.032 0.114 ↑ 1.0 63 1

Hash Left Join (cost=4.83..6.96 rows=63 width=153) (actual time=0.073..0.114 rows=63 loops=1)

  • Hash Cond: (taskmanage10_.id = children12_.parent_id)
26. 0.039 0.070 ↑ 1.0 63 1

Hash Right Join (cost=2.42..4.29 rows=63 width=102) (actual time=0.052..0.070 rows=63 loops=1)

  • Hash Cond: (taskmanage11_.id = taskmanage10_.parent_id)
27. 0.007 0.007 ↑ 1.0 63 1

Seq Scan on task_mgt_tag taskmanage11_ (cost=0.00..1.63 rows=63 width=51) (actual time=0.002..0.007 rows=63 loops=1)

28. 0.015 0.024 ↑ 1.0 63 1

Hash (cost=1.63..1.63 rows=63 width=51) (actual time=0.024..0.024 rows=63 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 13kB
29. 0.009 0.009 ↑ 1.0 63 1

Seq Scan on task_mgt_tag taskmanage10_ (cost=0.00..1.63 rows=63 width=51) (actual time=0.003..0.009 rows=63 loops=1)

30. 0.005 0.012 ↓ 0.0 0 1

Hash (cost=1.63..1.63 rows=63 width=51) (actual time=0.012..0.012 rows=0 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 8kB
31. 0.007 0.007 ↑ 1.0 63 1

Seq Scan on task_mgt_tag children12_ (cost=0.00..1.63 rows=63 width=51) (actual time=0.002..0.007 rows=63 loops=1)

32. 0.003 0.073 ↑ 1.0 8 1

Hash (cost=5.63..5.63 rows=8 width=8) (actual time=0.073..0.073 rows=8 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
33. 0.006 0.070 ↑ 1.0 8 1

HashAggregate (cost=5.55..5.63 rows=8 width=8) (actual time=0.069..0.070 rows=8 loops=1)

  • Group Key: project16_.business_id
34. 0.014 0.064 ↑ 1.0 8 1

Hash Join (cost=2.12..5.53 rows=8 width=8) (actual time=0.048..0.064 rows=8 loops=1)

  • Hash Cond: (projectmem15_.project_id = project16_.id)
35. 0.025 0.025 ↑ 1.0 8 1

Seq Scan on task_mgt_project_member projectmem15_ (cost=0.00..3.30 rows=8 width=8) (actual time=0.012..0.025 rows=8 loops=1)

  • Filter: ((user_id)::text = 'b976d6f8-a036-4898-84ef-b6e33ac4dd98'::text)
  • Rows Removed by Filter: 96
36. 0.013 0.025 ↑ 1.0 50 1

Hash (cost=1.50..1.50 rows=50 width=16) (actual time=0.025..0.025 rows=50 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 11kB
37. 0.012 0.012 ↑ 1.0 50 1

Seq Scan on task_mgt_project project16_ (cost=0.00..1.50 rows=50 width=16) (actual time=0.004..0.012 rows=50 loops=1)

38. 0.008 0.017 ↑ 1.0 19 1

Hash (cost=1.19..1.19 rows=19 width=1,056) (actual time=0.017..0.017 rows=19 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 10kB
39. 0.009 0.009 ↑ 1.0 19 1

Seq Scan on task_mgt_checklist_item checklisti3_ (cost=0.00..1.19 rows=19 width=1,056) (actual time=0.005..0.009 rows=19 loops=1)

40. 0.395 1.196 ↑ 1.0 1,459 1

Hash (cost=50.40..50.40 rows=1,459 width=169) (actual time=1.196..1.196 rows=1,459 loops=1)

  • Buckets: 2048 Batches: 1 Memory Usage: 153kB
41. 0.560 0.801 ↑ 1.0 1,459 1

Hash Left Join (cost=7.74..50.40 rows=1,459 width=169) (actual time=0.148..0.801 rows=1,459 loops=1)

  • Hash Cond: (tags4_.tag_id = taskmanage5_.id)
42. 0.110 0.110 ↑ 1.0 1,459 1

Seq Scan on task_mgt_tag_to_task tags4_ (cost=0.00..22.59 rows=1,459 width=16) (actual time=0.006..0.110 rows=1,459 loops=1)

43. 0.020 0.131 ↑ 1.0 63 1

Hash (cost=6.96..6.96 rows=63 width=153) (actual time=0.131..0.131 rows=63 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 14kB
44. 0.027 0.111 ↑ 1.0 63 1

Hash Left Join (cost=4.83..6.96 rows=63 width=153) (actual time=0.074..0.111 rows=63 loops=1)

  • Hash Cond: (taskmanage5_.id = children7_.parent_id)
45. 0.040 0.073 ↑ 1.0 63 1

Hash Right Join (cost=2.42..4.29 rows=63 width=102) (actual time=0.053..0.073 rows=63 loops=1)

  • Hash Cond: (taskmanage6_.id = taskmanage5_.parent_id)
46. 0.009 0.009 ↑ 1.0 63 1

Seq Scan on task_mgt_tag taskmanage6_ (cost=0.00..1.63 rows=63 width=51) (actual time=0.004..0.009 rows=63 loops=1)

47. 0.016 0.024 ↑ 1.0 63 1

Hash (cost=1.63..1.63 rows=63 width=51) (actual time=0.024..0.024 rows=63 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 13kB
48. 0.008 0.008 ↑ 1.0 63 1

Seq Scan on task_mgt_tag taskmanage5_ (cost=0.00..1.63 rows=63 width=51) (actual time=0.003..0.008 rows=63 loops=1)

49. 0.004 0.011 ↓ 0.0 0 1

Hash (cost=1.63..1.63 rows=63 width=51) (actual time=0.011..0.011 rows=0 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 8kB
50. 0.007 0.007 ↑ 1.0 63 1

Seq Scan on task_mgt_tag children7_ (cost=0.00..1.63 rows=63 width=51) (actual time=0.002..0.007 rows=63 loops=1)