explain.depesz.com

PostgreSQL's explain analyze made readable

Result: pinw

Settings
# exclusive inclusive rows x rows loops node
1. 0.000 0.000 ↓ 0.0

HashAggregate (cost=129,266.84..129,271.32 rows=448 width=344) (actual rows= loops=)

  • Group Key: dp.gsrn, dpc.componentnature, dp.market, address.street, address.number, address.box, address.postalcode, address.town, address.country, address.geographicalcode, dp.gridoperator, dp.transporter, dp.regulator, dp.sourceid, brps.brp
2.          

CTE fromdates

3. 0.000 0.000 ↓ 0.0

Sort (cost=97,760.47..98,559.74 rows=319,710 width=8) (actual rows= loops=)

  • Sort Key: generalconfig.deliverypointid, generalconfig.fromdate
4. 0.000 0.000 ↓ 0.0

HashAggregate (cost=65,331.64..68,528.74 rows=319,710 width=8) (actual rows= loops=)

  • Group Key: generalconfig.fromdate, generalconfig.deliverypointid
5. 0.000 0.000 ↓ 0.0

Append (cost=19,958.69..63,733.08 rows=319,710 width=8) (actual rows= loops=)

6. 0.000 0.000 ↓ 0.0

HashAggregate (cost=19,958.69..20,202.79 rows=24,410 width=8) (actual rows= loops=)

  • Group Key: generalconfig.fromdate, generalconfig.deliverypointid
7. 0.000 0.000 ↓ 0.0

Seq Scan on generalconfig (cost=0.00..19,524.10 rows=86,918 width=8) (actual rows= loops=)

  • Filter: ((deleted IS FALSE) AND ((fromdate <> todate) OR (todate IS NULL)) AND ((sourceid)::text = 'DGO'::text) AND ((status)::text = 'ACTUAL'::text))
8. 0.000 0.000 ↓ 0.0

HashAggregate (cost=4,394.45..5,075.27 rows=68,082 width=8) (actual rows= loops=)

  • Group Key: logicalconfig.fromdate, logicalconfig.deliverypointid
9. 0.000 0.000 ↓ 0.0

Seq Scan on logicalconfig (cost=0.00..3,804.55 rows=117,979 width=8) (actual rows= loops=)

  • Filter: ((deleted IS FALSE) AND ((fromdate <> todate) OR (todate IS NULL)) AND ((sourceid)::text = 'DGO'::text) AND ((status)::text = 'ACTUAL'::text))
10. 0.000 0.000 ↓ 0.0

HashAggregate (cost=19,958.69..20,202.79 rows=24,410 width=8) (actual rows= loops=)

  • Group Key: generalconfig_1.todate, generalconfig_1.deliverypointid
11. 0.000 0.000 ↓ 0.0

Seq Scan on generalconfig generalconfig_1 (cost=0.00..19,524.10 rows=86,918 width=8) (actual rows= loops=)

  • Filter: ((deleted IS FALSE) AND ((fromdate <> todate) OR (todate IS NULL)) AND ((sourceid)::text = 'DGO'::text) AND ((status)::text = 'ACTUAL'::text))
12. 0.000 0.000 ↓ 0.0

HashAggregate (cost=4,394.45..5,075.27 rows=68,082 width=8) (actual rows= loops=)

  • Group Key: logicalconfig_1.todate, logicalconfig_1.deliverypointid
13. 0.000 0.000 ↓ 0.0

Seq Scan on logicalconfig logicalconfig_1 (cost=0.00..3,804.55 rows=117,979 width=8) (actual rows= loops=)

  • Filter: ((deleted IS FALSE) AND ((fromdate <> todate) OR (todate IS NULL)) AND ((sourceid)::text = 'DGO'::text) AND ((status)::text = 'ACTUAL'::text))
14. 0.000 0.000 ↓ 0.0

HashAggregate (cost=4,316.30..4,989.93 rows=67,363 width=8) (actual rows= loops=)

  • Group Key: physicalconfig.fromdate, physicalconfig.deliverypointid
15. 0.000 0.000 ↓ 0.0

Seq Scan on physicalconfig (cost=0.00..3,715.17 rows=120,226 width=8) (actual rows= loops=)

  • Filter: ((deleted IS FALSE) AND ((fromdate <> todate) OR (todate IS NULL)) AND ((sourceid)::text = 'DGO'::text) AND ((status)::text = 'ACTUAL'::text))
16. 0.000 0.000 ↓ 0.0

HashAggregate (cost=4,316.30..4,989.93 rows=67,363 width=8) (actual rows= loops=)

  • Group Key: physicalconfig_1.todate, physicalconfig_1.deliverypointid
17. 0.000 0.000 ↓ 0.0

Seq Scan on physicalconfig physicalconfig_1 (cost=0.00..3,715.17 rows=120,226 width=8) (actual rows= loops=)

  • Filter: ((deleted IS FALSE) AND ((fromdate <> todate) OR (todate IS NULL)) AND ((sourceid)::text = 'DGO'::text) AND ((status)::text = 'ACTUAL'::text))
18.          

CTE brps

19. 0.000 0.000 ↓ 0.0

Subquery Scan on x (cost=14,427.49..17,336.53 rows=448 width=10) (actual rows= loops=)

  • Filter: (x.nbr = 1)
20. 0.000 0.000 ↓ 0.0

WindowAgg (cost=14,427.49..16,217.67 rows=89,509 width=14) (actual rows= loops=)

21. 0.000 0.000 ↓ 0.0

Sort (cost=14,427.49..14,651.26 rows=89,509 width=14) (actual rows= loops=)

  • Sort Key: deliveryperiod.deliverypointid, brpj.fromdate
22. 0.000 0.000 ↓ 0.0

Hash Join (cost=3,031.95..7,065.49 rows=89,509 width=14) (actual rows= loops=)

  • Hash Cond: (deliveryperiod.deliveryperiodid = brpj.deliveryperiodid)
23. 0.000 0.000 ↓ 0.0

Seq Scan on deliveryperiod (cost=0.00..2,355.17 rows=89,517 width=8) (actual rows= loops=)

24. 0.000 0.000 ↓ 0.0

Hash (cost=1,913.09..1,913.09 rows=89,509 width=14) (actual rows= loops=)

25. 0.000 0.000 ↓ 0.0

Seq Scan on deliveryperiodbrpjournal brpj (cost=0.00..1,913.09 rows=89,509 width=14) (actual rows= loops=)

26.          

CTE address

27. 0.000 0.000 ↓ 0.0

Subquery Scan on x_1 (cost=10,480.19..10,495.08 rows=2 width=70) (actual rows= loops=)

  • Filter: (x_1.nbr = 1)
28. 0.000 0.000 ↓ 0.0

WindowAgg (cost=10,480.19..10,489.35 rows=458 width=72) (actual rows= loops=)

29. 0.000 0.000 ↓ 0.0

Sort (cost=10,480.19..10,481.34 rows=458 width=72) (actual rows= loops=)

  • Sort Key: fa.addressid, fad.addressdetailnbr
30. 0.000 0.000 ↓ 0.0

Nested Loop (cost=9,359.04..10,459.95 rows=458 width=72) (actual rows= loops=)

31. 0.000 0.000 ↓ 0.0

Merge Left Join (cost=9,358.75..10,280.09 rows=458 width=36) (actual rows= loops=)

  • Merge Cond: (((fa.country)::text = (tj.country)::text) AND ((fa.postalcode)::text = (tj.postalcode)::text) AND (fa.towncode = tj.towncode))
  • Filter: (tj.todate IS NULL)
32. 0.000 0.000 ↓ 0.0

Sort (cost=9,316.96..9,545.85 rows=91,557 width=72) (actual rows= loops=)

  • Sort Key: fa.country, fa.postalcode, fa.towncode
33. 0.000 0.000 ↓ 0.0

Seq Scan on freeaddresses fa (cost=0.00..1,771.57 rows=91,557 width=72) (actual rows= loops=)

34. 0.000 0.000 ↓ 0.0

Sort (cost=41.79..43.22 rows=570 width=104) (actual rows= loops=)

  • Sort Key: tj.country, tj.postalcode, tj.towncode
35. 0.000 0.000 ↓ 0.0

Seq Scan on townjournal tj (cost=0.00..15.70 rows=570 width=104) (actual rows= loops=)

36. 0.000 0.000 ↓ 0.0

Index Scan using freeadddetail_addressid_idx on freeaddressesdetail fad (cost=0.29..0.38 rows=1 width=40) (actual rows= loops=)

  • Index Cond: (addressid = fa.addressid)
37. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=0.71..2,858.69 rows=448 width=344) (actual rows= loops=)

  • Join Filter: (dp.addressid = address.addressid)
38. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.71..2,838.51 rows=448 width=124) (actual rows= loops=)

39. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.29..2,565.44 rows=448 width=48) (actual rows= loops=)

40. 0.000 0.000 ↓ 0.0

CTE Scan on brps (cost=0.00..8.96 rows=448 width=36) (actual rows= loops=)

41. 0.000 0.000 ↓ 0.0

Index Scan using dpcomp_deliverypointid_idx on deliverypointcomponent dpc (cost=0.29..5.70 rows=1 width=12) (actual rows= loops=)

  • Index Cond: (deliverypointid = brps.deliverypointid)
42. 0.000 0.000 ↓ 0.0

Index Scan using deliverypoint_pkey on deliverypoint dp (cost=0.42..0.60 rows=1 width=88) (actual rows= loops=)

  • Index Cond: (deliverypointid = dpc.deliverypointid)
43. 0.000 0.000 ↓ 0.0

CTE Scan on address (cost=0.00..0.04 rows=2 width=228) (actual rows= loops=)