explain.depesz.com

PostgreSQL's explain analyze made readable

Result: rKuL

Settings
# exclusive inclusive rows x rows loops node
1. 29.236 1,382.621 ↑ 1.0 1 1

Aggregate (cost=5,736,143.06..5,736,143.07 rows=1 width=80) (actual time=1,382.621..1,382.621 rows=1 loops=1)

2. 26.872 1,353.385 ↓ 18.9 273,896 1

Nested Loop (cost=277.44..5,736,034.20 rows=14,514 width=36) (actual time=0.076..1,353.385 rows=273,896 loops=1)

3. 0.081 0.081 ↓ 2.3 328 1

Seq Scan on industrycompanies ic (cost=0.00..11.40 rows=140 width=4) (actual time=0.006..0.081 rows=328 loops=1)

4. 1,250.008 1,326.432 ↓ 8.0 835 328

Bitmap Heap Scan on instntradesummary x0 (cost=277.44..40,970.55 rows=104 width=47) (actual time=0.309..4.044 rows=835 loops=328)

  • Recheck Cond: ((keyinstn = ic.keyinstn) AND (updoperation < 2))
  • Filter: ((((tradedatayear)::double precision > date_part('year'::text, (CURRENT_DATE + '-2 years'::interval))) AND ((tradedatayear)::double precision < date_part('year'::text, (CURRENT_DATE)::timestamp without time zone))) OR (((tradedatayear)::double precision = date_part('year'::text, (CURRENT_DATE + '-2 years'::interval))) AND ((tradedatamonth)::double precision >= date_part('month'::text, (CURRENT_DATE)::timestamp without time zone))) OR (((tradedatayear)::double precision = date_part('year'::text, (CURRENT_DATE)::timestamp without time zone)) AND ((tradedatamonth)::double precision <= date_part('month'::text, (CURRENT_DATE)::timestamp without time zone))))
  • Rows Removed by Filter: 4004
  • Heap Blocks: exact=189137
5. 76.424 76.424 ↑ 2.6 4,839 328

Bitmap Index Scan on ix_instntradesummary_sk (cost=0.00..277.41 rows=12,470 width=0) (actual time=0.233..0.233 rows=4,839 loops=328)

  • Index Cond: (keyinstn = ic.keyinstn)
Planning time : 0.347 ms