explain.depesz.com

A tool for finding a real cause for slow queries.

Result: HPu

options
Did it help? Consider supporting us - Bitcoin address: 12v2hUztAk2LgzQ9H9LMwuU32urHMjZQnq
# exclusive inclusive rows x rows loops node
1. 4,633.545 25,572.796 ↑ 1.1 1,000,000 1

Merge Join (cost=991,545.77..1,008,695.35 rows=1,128,213 width=413) (actual time=15,639.913..25,572.796 rows=1,000,000 loops=1)

  • Merge Cond: ((fs_debtitem.fs_party)::text = (fs_agrperson.fs_party)::text)
2. 909.505 1,547.102 ↑ 1.8 28,134 1

Sort (cost=93,659.96..93,789.51 rows=51,822 width=66) (actual time=1,396.111..1,547.102 rows=28,134 loops=1)

  • Sort Key: fs_debtitem.fs_party
  • Sort Method: external merge Disk: 3616kB
3. 637.597 637.597 ↑ 1.1 45,351 1

Seq Scan on fs_debtitem (cost=0.00..87,473.96 rows=51,822 width=66) (actual time=0.120..637.597 rows=45,351 loops=1)

  • Filter: (fs_annualize = 0)
4. 3,432.506 19,392.149 ↓ 1.0 1,000,000 1

Materialize (cost=897,885.24..910,226.91 rows=987,333 width=380) (actual time=14,023.625..19,392.149 rows=1,000,000 loops=1)

5. 8,126.711 15,959.643 ↓ 1.0 1,000,000 1

Sort (cost=897,885.24..900,353.58 rows=987,333 width=380) (actual time=14,023.614..15,959.643 rows=1,000,000 loops=1)

  • Sort Key: fs_agrperson.fs_party
  • Sort Method: external sort Disk: 312664kB
6. 5,013.353 7,832.932 ↓ 1.0 1,000,000 1

Hash Join (cost=2,890.40..283,253.56 rows=987,333 width=380) (actual time=5,063.392..7,832.932 rows=1,000,000 loops=1)

  • Hash Cond: ((cm_ledgeritem.salesteam)::text = (fs_agrperson.tril_gid)::text)
7. 2,629.496 2,629.496 ↓ 1.0 1,000,000 1

Seq Scan on cm_ledgeritem (cost=0.00..173,151.00 rows=987,333 width=347) (actual time=206.101..2,629.496 rows=1,000,000 loops=1)

  • Filter: (fs_batchid = 1)
8. 82.595 190.083 ↑ 1.0 45,351 1

Hash (cost=1,791.51..1,791.51 rows=45,351 width=66) (actual time=190.083..190.083 rows=45,351 loops=1)

9. 107.488 107.488 ↑ 1.0 45,351 1

Seq Scan on fs_agrperson (cost=0.00..1,791.51 rows=45,351 width=66) (actual time=0.010..107.488 rows=45,351 loops=1)