explain.depesz.com

PostgreSQL's explain analyze made readable

Result: B3eC : Optimization for: plan #4gt

Settings

Optimization path:

Optimization(s) for this plan:

# exclusive inclusive rows x rows loops node
1. 0.006 393.359 ↓ 3.3 30 1

Limit (cost=130,103.82..130,357.34 rows=9 width=102) (actual time=393.163..393.359 rows=30 loops=1)

2. 0.010 393.353 ↓ 3.3 30 1

Nested Loop (cost=130,103.82..130,357.34 rows=9 width=102) (actual time=393.161..393.353 rows=30 loops=1)

3. 0.003 393.133 ↑ 1.0 30 1

Limit (cost=130,103.39..130,103.47 rows=30 width=70) (actual time=393.129..393.133 rows=30 loops=1)

4. 14.450 393.130 ↑ 2,416.5 30 1

Sort (cost=130,103.39..130,284.63 rows=72,496 width=70) (actual time=393.128..393.130 rows=30 loops=1)

  • Sort Key: (similarity(searchclient.searchclient_nom, 'jean'::text)) DESC
  • Sort Method: top-N heapsort Memory: 32kB
5. 348.072 378.680 ↑ 1.4 53,080 1

Bitmap Heap Scan on searchclient (cost=1,338.08..127,962.26 rows=72,496 width=70) (actual time=45.972..378.680 rows=53,080 loops=1)

  • Recheck Cond: (searchclient_meta ~~ '%JN %'::text)
  • Rows Removed by Index Recheck: 78
  • Filter: (searchclient_dossier_id = 15)
  • Rows Removed by Filter: 50,070
  • Heap Blocks: exact=55,180
6. 30.608 30.608 ↑ 1.4 103,228 1

Bitmap Index Scan on searchclient_meta_sp (cost=0.00..1,319.96 rows=145,594 width=0) (actual time=30.608..30.608 rows=103,228 loops=1)

  • Index Cond: (searchclient_meta ~~ '%JN %'::text)
7. 0.210 0.210 ↑ 1.0 1 30

Index Scan using client_dossierid_sk on client (cost=0.43..8.45 rows=1 width=4) (actual time=0.007..0.007 rows=1 loops=30)

  • Index Cond: ((client_dossier_id = 15) AND (client_id = searchclient.searchclient_client_id))
  • Filter: (client_etat = 0)