explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 5MIi

Settings
# exclusive inclusive rows x rows loops node
1. 0.004 7,705.170 ↑ 1.0 1 1

Aggregate (cost=244.73..244.74 rows=1 width=40) (actual time=7,705.170..7,705.170 rows=1 loops=1)

2. 0.010 7,705.166 ↓ 0.0 0 1

Hash Join (cost=219.88..244.62 rows=15 width=48) (actual time=7,705.166..7,705.166 rows=0 loops=1)

  • Hash Cond: (d.attachmentid = att.id)
3. 0.035 0.035 ↑ 906.0 1 1

Seq Scan on document d (cost=0.00..20.06 rows=906 width=52) (actual time=0.035..0.035 rows=1 loops=1)

4. 0.001 7,705.121 ↓ 0.0 0 1

Hash (cost=219.69..219.69 rows=15 width=4) (actual time=7,705.121..7,705.121 rows=0 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 8kB
5. 7,705.120 7,705.120 ↓ 0.0 0 1

Foreign Scan on attachment att (cost=100.00..219.69 rows=15 width=4) (actual time=7,705.120..7,705.120 rows=0 loops=1)

  • Filter: (date(dateadded) = CURRENT_DATE)
  • Rows Removed by Filter: 998765
Planning time : 0.321 ms