explain.depesz.com

PostgreSQL's explain analyze made readable

Result: NpTe

Settings
# exclusive inclusive rows x rows loops node
1. 2,488.008 2,490.268 ↑ 130.2 12,612 1

Index Only Scan using index_tenants_on_account_id_and_id_and_deleted_at on tenants (cost=4.18..105,452.41 rows=1,641,812 width=4) (actual time=1,828.272..2,490.268 rows=12,612 loops=1)

  • Index Cond: (deleted_at IS NULL)
  • Filter: ((id = 2,906,683) OR (hashed SubPlan 1))
  • Rows Removed by Filter: 2,687,201
  • Heap Fetches: 2,698,956
  • Functions: 17
  • Options: Inlining false, Optimization false, Expressions true, Deforming true
  • Timing: Generation 2.019 ms, Inlining 0.000 ms, Optimization 0.597 ms, Emission 10.858 ms, Total 13.474 ms
2.          

SubPlan (for Index Only Scan)

3. 2.260 2.260 ↑ 1.0 1 1

Index Scan using tenants_pkey on tenants tenants_1 (cost=0.09..4.09 rows=1 width=4) (actual time=2.258..2.260 rows=1 loops=1)

  • Index Cond: (id = 2,906,683)
  • Filter: (deleted_at IS NULL)
Planning time : 0.202 ms
Execution time : 2,492.693 ms