explain.depesz.com

PostgreSQL's explain analyze made readable

Result: sTET

Settings
# exclusive inclusive rows x rows loops node
1. 0.011 123.396 ↑ 1.0 10 1

Limit (cost=46,748.72..46,748.74 rows=10 width=5,755) (actual time=123.386..123.396 rows=10 loops=1)

2. 0.092 123.385 ↑ 976.7 10 1

Sort (cost=46,748.72..46,773.13 rows=9,767 width=5,755) (actual time=123.384..123.385 rows=10 loops=1)

  • Sort Key: o.date_time_create DESC
  • Sort Method: top-N heapsort Memory: 63kB
3. 2.614 123.293 ↑ 424.7 23 1

HashAggregate (cost=46,342.31..46,439.98 rows=9,767 width=5,755) (actual time=123.126..123.293 rows=23 loops=1)

  • Group Key: o.id, o.id_ek5, o.number, o.date_time_create, o.user_created_code, o.order_type_code, o.note, o.true_delivery_mode_code, o.ek4_id, o.sender, o.sender_contragent_code, o.receiver, o.receiver_contragent_code, o.payer, o.payer_contragent_code, o.method_of_payment_code, o.payer_type_code, o.packages, o.volume_weight, o.calc_weight, o.online_shop, o.international, o.is_international, o.tariff_type_code, o.additional_services, o.discounts, o.extra_charges, o.common_currency_code, o.declared_cost_currency_code, o.cash_on_delivery_currency_code, o.delivery_price, o.from_office, o.order_status_code, o.order_additional_status_code, o.interface_code, o.responsible_for_delivery_branch_code, o.deleted, o.create_time, o.update_time, o.reverse_ek5_id, o.straight_ek5_id, o.total_amount, o.thresholds, o.real_weight, o.courier_invitation_code
4. 0.018 120.679 ↑ 232.5 42 1

Append (cost=0.56..45,243.53 rows=9,767 width=5,755) (actual time=0.090..120.679 rows=42 loops=1)

5. 58.006 58.006 ↑ 270.2 18 1

Index Scan using idx_order_sender_code on "order" o (cost=0.56..22,452.82 rows=4,864 width=1,976) (actual time=0.089..58.006 rows=18 loops=1)

  • Index Cond: ((sender_contragent_code)::text = '56090b33d83467dd84bd15ce'::text)
  • Filter: ((NOT deleted) AND (date_time_create >= '2019-08-07 00:00:00'::timestamp without time zone) AND (date_time_create <= '2019-09-07 23:59:59'::timestamp without time zone))
  • Rows Removed by Filter: 22122
6. 0.092 0.092 ↑ 39.0 1 1

Index Scan using idx_order_receiver_code on "order" o_1 (cost=0.56..180.13 rows=39 width=1,976) (actual time=0.087..0.092 rows=1 loops=1)

  • Index Cond: ((receiver_contragent_code)::text = '56090b33d83467dd84bd15ce'::text)
  • Filter: ((NOT deleted) AND (date_time_create >= '2019-08-07 00:00:00'::timestamp without time zone) AND (date_time_create <= '2019-09-07 23:59:59'::timestamp without time zone))
  • Rows Removed by Filter: 11
7. 62.563 62.563 ↑ 211.5 23 1

Index Scan using idx_order_payer_code on "order" o_2 (cost=0.56..22,464.07 rows=4,864 width=1,976) (actual time=0.089..62.563 rows=23 loops=1)

  • Index Cond: ((payer_contragent_code)::text = '56090b33d83467dd84bd15ce'::text)
  • Filter: ((NOT deleted) AND (date_time_create >= '2019-08-07 00:00:00'::timestamp without time zone) AND (date_time_create <= '2019-09-07 23:59:59'::timestamp without time zone))
  • Rows Removed by Filter: 22236
Planning time : 1.590 ms
Execution time : 123.659 ms