explain.depesz.com

PostgreSQL's explain analyze made readable

Result: a9wM

Settings
# exclusive inclusive rows x rows loops node
1. 8.271 296.057 ↓ 795.0 795 1

Unique (cost=6,892.30..6,892.30 rows=1 width=92) (actual time=287.669..296.057 rows=795 loops=1)

2. 0.959 287.786 ↓ 800.0 800 1

Sort (cost=6,892.30..6,892.30 rows=1 width=92) (actual time=287.668..287.786 rows=800 loops=1)

  • Sort Key: feedback_customer_feedback.order_id
  • Sort Method: quicksort Memory: 87kB
3. 0.890 286.827 ↓ 800.0 800 1

Nested Loop (cost=3,960.83..6,892.29 rows=1 width=92) (actual time=92.739..286.827 rows=800 loops=1)

4. 0.511 281.937 ↓ 800.0 800 1

Nested Loop (cost=3,960.56..6,891.98 rows=1 width=100) (actual time=92.713..281.937 rows=800 loops=1)

5. 0.709 274.226 ↓ 800.0 800 1

Nested Loop Left Join (cost=3,960.13..6,886.85 rows=1 width=100) (actual time=92.684..274.226 rows=800 loops=1)

6. 12.364 271.117 ↓ 800.0 800 1

Nested Loop (cost=3,959.86..6,886.30 rows=1 width=32) (actual time=92.660..271.117 rows=800 loops=1)

7. 8.802 118.920 ↓ 485.5 15,537 1

Hash Join (cost=3,951.13..6,413.02 rows=32 width=24) (actual time=88.003..118.920 rows=15,537 loops=1)

  • Hash Cond: (feedback_customer_feedback.writer_id = writers_writer.id)
8. 22.423 24.343 ↓ 2.8 17,755 1

Bitmap Heap Scan on feedback_customer_feedback (cost=376.67..2,814.17 rows=6,418 width=20) (actual time=2.188..24.343 rows=17,755 loops=1)

  • Filter: ((NOT is_deleted) AND is_approved AND is_shareable AND ((comment)::text <> ''::text) AND (paper_rating > 8) AND (paper_rating <= 10))
  • Rows Removed by Filter: 1281
  • Heap Blocks: exact=1744
9. 1.920 1.920 ↑ 1.1 19,036 1

Bitmap Index Scan on feedback_is_shareable__idx (cost=0.00..375.06 rows=20,086 width=0) (actual time=1.920..1.920 rows=19,036 loops=1)

  • Index Cond: (is_shareable = true)
10. 0.631 85.775 ↓ 5.7 1,450 1

Hash (cost=3,571.27..3,571.27 rows=255 width=4) (actual time=85.775..85.775 rows=1,450 loops=1)

  • Buckets: 2048 (originally 1024) Batches: 1 (originally 1) Memory Usage: 67kB
11. 85.144 85.144 ↓ 5.7 1,450 1

Seq Scan on writers_writer (cost=0.00..3,571.27 rows=255 width=4) (actual time=0.085..85.144 rows=1,450 loops=1)

  • Filter: ((status)::text ~~ 'active:%'::text)
  • Rows Removed by Filter: 49671
12. 139.816 139.833 ↓ 0.0 0 15,537

Index Scan using essays_order_pkey on essays_order (cost=8.73..14.78 rows=1 width=16) (actual time=0.009..0.009 rows=0 loops=15,537)

  • Index Cond: (id = feedback_customer_feedback.order_id)
  • Filter: ((level_work_id = 2) AND (paper_subject_id = 359) AND (NOT (hashed SubPlan 1)))
  • Rows Removed by Filter: 1
13.          

SubPlan (forIndex Scan)

14. 0.017 0.017 ↓ 0.0 0 1

Index Scan using customers_writer_blacklist_customer_id_idx on customers_writer_blacklist u0 (cost=0.28..8.30 rows=1 width=4) (actual time=0.017..0.017 rows=0 loops=1)

  • Index Cond: (customer_id = 617936)
  • Filter: is_active
15. 2.400 2.400 ↑ 1.0 1 800

Index Scan using writers_widget_stats_view_writer_id_uniq on writers_widget_stats_view (cost=0.28..0.55 rows=1 width=76) (actual time=0.003..0.003 rows=1 loops=800)

  • Index Cond: (writers_writer.id = writer_id)
16. 7.200 7.200 ↑ 1.0 1 800

Index Scan using customers_customer_pkey on customers_customer (cost=0.42..5.11 rows=1 width=12) (actual time=0.009..0.009 rows=1 loops=800)

  • Index Cond: (id = essays_order.customer_id)
17. 4.000 4.000 ↑ 1.0 1 800

Index Scan using core_site_pkey on core_site (cost=0.28..0.30 rows=1 width=4) (actual time=0.003..0.005 rows=1 loops=800)

  • Index Cond: (id = customers_customer.site_id)
  • Filter: (region_id = 2)
Planning time : 2.260 ms
Execution time : 296.567 ms