explain.depesz.com

PostgreSQL's explain analyze made readable

Result: c4Z9

Settings
# exclusive inclusive rows x rows loops node
1. 69,854.614 223,990.266 ↓ 0.0 0 1

Delete on infos_proposition_commande (cost=6,182,742.33..7,966,756.84 rows=895,842 width=24) (actual time=223,990.266..223,990.266 rows=0 loops=1)

2. 12,248.475 154,135.652 ↓ 4.0 3,552,587 1

Hash Semi Join (cost=6,182,742.33..7,966,756.84 rows=895,842 width=24) (actual time=134,840.396..154,135.652 rows=3,552,587 loops=1)

  • Hash Cond: (infos_proposition_commande.id = ipc.id)
3. 29,772.199 29,772.199 ↑ 1.0 11,779,337 1

Seq Scan on infos_proposition_commande (cost=0.00..1,620,362.90 rows=11,909,090 width=14) (actual time=0.979..29,772.199 rows=11,779,337 loops=1)

4. 1,369.848 112,114.978 ↓ 4.0 3,552,587 1

Hash (cost=6,165,420.31..6,165,420.31 rows=895,842 width=26) (actual time=112,114.978..112,114.978 rows=3,552,587 loops=1)

  • Buckets: 1048576 (originally 1048576) Batches: 8 (originally 2) Memory Usage: 43009kB
5. 9,548.116 110,745.130 ↓ 4.0 3,552,587 1

Hash Join (cost=1,873,186.68..6,165,420.31 rows=895,842 width=26) (actual time=38,113.034..110,745.130 rows=3,552,587 loops=1)

  • Hash Cond: (lc.id = ipc.ligne_commande_id)
6. 13,365.958 63,318.007 ↓ 1.0 9,360,451 1

Hash Join (cost=34,180.16..3,980,635.02 rows=9,139,334 width=20) (actual time=194.786..63,318.007 rows=9,360,451 loops=1)

  • Hash Cond: (lc.commande_id = c.id)
7. 49,761.022 49,761.022 ↑ 1.0 118,281,074 1

Seq Scan on ligne_commande lc (cost=0.00..3,627,527.08 rows=121,495,908 width=22) (actual time=0.930..49,761.022 rows=118,281,074 loops=1)

8. 26.203 191.027 ↓ 1.0 99,783 1

Hash (cost=32,936.87..32,936.87 rows=99,463 width=14) (actual time=191.026..191.027 rows=99,783 loops=1)

  • Buckets: 131072 Batches: 1 Memory Usage: 5702kB
9. 143.010 164.824 ↓ 1.0 99,783 1

Bitmap Heap Scan on commande c (cost=2,119.92..32,936.87 rows=99,463 width=14) (actual time=22.215..164.824 rows=99,783 loops=1)

  • Recheck Cond: ((date_commande > '2019-10-01'::date) AND (date_commande < '2019-11-01'::date))
  • Heap Blocks: exact=2985
10. 21.814 21.814 ↓ 1.0 99,783 1

Bitmap Index Scan on commande_date_commande_idx (cost=0.00..2,095.06 rows=99,463 width=0) (actual time=21.814..21.814 rows=99,783 loops=1)

  • Index Cond: ((date_commande > '2019-10-01'::date) AND (date_commande < '2019-11-01'::date))
11. 4,979.580 37,879.007 ↑ 1.0 11,779,337 1

Hash (cost=1,620,362.90..1,620,362.90 rows=11,909,090 width=22) (actual time=37,879.007..37,879.007 rows=11,779,337 loops=1)

  • Buckets: 1048576 Batches: 16 Memory Usage: 48493kB
12. 32,899.427 32,899.427 ↑ 1.0 11,779,337 1

Seq Scan on infos_proposition_commande ipc (cost=0.00..1,620,362.90 rows=11,909,090 width=22) (actual time=0.033..32,899.427 rows=11,779,337 loops=1)

Planning time : 94.184 ms
Execution time : 224,006.418 ms