explain.depesz.com

PostgreSQL's explain analyze made readable

Result: mRvg

Settings
# exclusive inclusive rows x rows loops node
1. 0.045 0.676 ↓ 2.0 4 1

Sort (cost=32.60..32.61 rows=2 width=240) (actual time=0.676..0.676 rows=4 loops=1)

  • Sort Key: e.created_date
  • Sort Method: quicksort Memory: 26kB
2. 0.107 0.631 ↓ 2.0 4 1

Nested Loop (cost=15.25..32.59 rows=2 width=240) (actual time=0.545..0.631 rows=4 loops=1)

3. 0.042 0.042 ↑ 1.0 1 1

Seq Scan on story s (cost=0.00..1.55 rows=1 width=37) (actual time=0.034..0.042 rows=1 loops=1)

  • Filter: (participation AND (NOT banned) AND (NOT deleted) AND ((id)::text = bfff7e3c-e83b-11e7-80c1-9a214cf093ae::text))
  • Rows Removed by Filter: 44
4. 0.040 0.407 ↓ 2.0 4 1

Hash Right Join (cost=15.25..16.78 rows=2 width=275) (actual time=0.367..0.407 rows=4 loops=1)

  • Hash Cond: ((entry_up_detail.entry_fk)::text = (e.id)::text)
5. 0.112 0.142 ↓ 1.0 65 1

HashAggregate (cost=3.74..4.38 rows=64 width=45) (actual time=0.121..0.142 rows=65 loops=1)

  • Group Key: entry_up_detail.entry_fk
6. 0.030 0.030 ↓ 1.1 124 1

Seq Scan on entry_up_detail (cost=0.00..3.16 rows=116 width=37) (actual time=0.010..0.030 rows=124 loops=1)

7. 0.014 0.225 ↓ 2.0 4 1

Hash (cost=11.48..11.48 rows=2 width=267) (actual time=0.225..0.225 rows=4 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 10kB
8. 0.026 0.211 ↓ 2.0 4 1

Hash Join (cost=10.04..11.48 rows=2 width=267) (actual time=0.208..0.211 rows=4 loops=1)

  • Hash Cond: ((up.user_fk)::text = (u.id)::text)
9. 0.017 0.017 ↓ 1.2 36 1

Seq Scan on user_preference up (cost=0.00..1.31 rows=31 width=38) (actual time=0.007..0.017 rows=36 loops=1)

10. 0.007 0.168 ↑ 1.2 4 1

Hash (cost=9.97..9.97 rows=5 width=303) (actual time=0.168..0.168 rows=4 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 10kB
11. 0.039 0.161 ↑ 1.2 4 1

Hash Join (cost=6.61..9.97 rows=5 width=303) (actual time=0.153..0.161 rows=4 loops=1)

  • Hash Cond: ((u.id)::text = (e.owner_fk)::text)
12. 0.017 0.017 ↑ 1.9 36 1

Seq Scan on users u (cost=0.00..2.70 rows=70 width=49) (actual time=0.011..0.017 rows=36 loops=1)

13. 0.014 0.105 ↑ 1.2 4 1

Hash (cost=6.55..6.55 rows=5 width=254) (actual time=0.105..0.105 rows=4 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 10kB
14. 0.091 0.091 ↑ 1.2 4 1

Seq Scan on entry e (cost=0.00..6.55 rows=5 width=254) (actual time=0.009..0.091 rows=4 loops=1)

  • Filter: (confirmed AND (NOT banned) AND (NOT deleted) AND ((story_fk)::text = bfff7e3c-e83b-11e7-80c1-9a214cf093ae::text))
  • Rows Removed by Filter: 120
15.          

SubPlan (forNested Loop)

16. 0.000 0.000 ↓ 0.0 0

Seq Scan on entry_up_detail eud (cost=0.00..3.74 rows=1 width=0) (never executed)

  • Filter: (((e.id)::text = (entry_fk)::text) AND ((upper_fk)::text = 5209e2a2-f08f-4649-8c27-d883c6ee4f61::text))
17. 0.039 0.039 ↓ 1.1 59 1

Seq Scan on entry_up_detail eud_1 (cost=0.00..3.45 rows=55 width=32) (actual time=0.007..0.039 rows=59 loops=1)

  • Filter: ((upper_fk)::text = 5209e2a2-f08f-4649-8c27-d883c6ee4f61::text)
  • Rows Removed by Filter: 65
18. 0.000 0.000 ↓ 0.0 0

Seq Scan on user_relationship ur (cost=0.00..3.38 rows=1 width=0) (never executed)

  • Filter: (((u.id)::text = (related_user_fk)::text) AND ((user_fk)::text = 5209e2a2-f08f-4649-8c27-d883c6ee4f61::text) AND (type_fk = 31520))
19. 0.036 0.036 ↑ 1.2 17 1

Seq Scan on user_relationship ur_1 (cost=0.00..3.19 rows=21 width=32) (actual time=0.012..0.036 rows=17 loops=1)

  • Filter: (((user_fk)::text = 5209e2a2-f08f-4649-8c27-d883c6ee4f61::text) AND (type_fk = 31520))
  • Rows Removed by Filter: 63