explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 34Pe

Settings
# exclusive inclusive rows x rows loops node
1. 548.700 42,596.472 ↑ 1.0 100 1

Limit (cost=135,911.84..135,911.89 rows=100 width=733) (actual time=42,596.447..42,596.472 rows=100 loops=1)

  • Functions: 20
  • Options: Inlining false, Optimization false, Expressions true, Deforming true
  • Timing: Generation 4.150 ms, Inlining 0.000 ms, Optimization 30.595 ms, Emission 517.731 ms, Total 552.475 ms
2. 126.532 42,047.772 ↑ 734.6 100 1

Sort (cost=135,911.84..135,948.57 rows=73,464 width=733) (actual time=42,047.755..42,047.772 rows=100 loops=1)

  • Sort Key: c."dateTimeOpened", c."ticketNumber" DESC
  • Sort Method: top-N heapsort Memory: 203kB
3. 154.319 41,921.240 ↓ 1.2 84,578 1

Nested Loop (cost=617.52..135,350.29 rows=73,464 width=733) (actual time=200.701..41,921.240 rows=84,578 loops=1)

4. 1.249 1.249 ↑ 241.0 1 1

CTE Scan on subaccounts (cost=613.01..614.45 rows=241 width=722) (actual time=0.037..1.249 rows=1 loops=1)

5.          

CTE subaccounts

6. 0.004 1.244 ↑ 241.0 1 1

Recursive Union (cost=0.08..613.01 rows=241 width=67) (actual time=0.034..1.244 rows=1 loops=1)

7. 0.035 0.035 ↑ 1.0 1 1

Index Scan using account_sfid_key on account p (cost=0.08..4.09 rows=1 width=67) (actual time=0.031..0.035 rows=1 loops=1)

  • Index Cond: ((sfid)::text = ANY ('{0016000001Cs4zlAAB}'::text[]))
8. 0.016 1.205 ↓ 0.0 0 1

Nested Loop (cost=0.08..60.75 rows=24 width=67) (actual time=1.204..1.205 rows=0 loops=1)

9. 0.003 0.003 ↑ 10.0 1 1

WorkTable Scan on subaccounts s (cost=0.00..0.06 rows=10 width=54) (actual time=0.003..0.003 rows=1 loops=1)

10. 1.186 1.186 ↓ 0.0 0 1

Index Scan using account_parentid_idx on account c_1 (cost=0.08..6.06 rows=2 width=67) (actual time=1.186..1.186 rows=0 loops=1)

  • Index Cond: ((parentid)::text = (s.sfid)::text)
11. 41,658.192 41,765.672 ↓ 277.3 84,578 1

Bitmap Heap Scan on mv_case c (cost=4.51..558.15 rows=305 width=752) (actual time=200.642..41,765.672 rows=84,578 loops=1)

  • Recheck Cond: (("accountId")::text = (subaccounts.sfid)::text)
  • Heap Blocks: exact=55,825
12. 107.480 107.480 ↓ 277.3 84,578 1

Bitmap Index Scan on "accountId_new_index" (cost=0.00..4.49 rows=305 width=0) (actual time=107.479..107.480 rows=84,578 loops=1)

  • Index Cond: (("accountId")::text = (subaccounts.sfid)::text)
Execution time : 42,601.428 ms