explain.depesz.com

PostgreSQL's explain analyze made readable

Result: fv1t

Settings
# exclusive inclusive rows x rows loops node
1. 0.007 20,425.270 ↑ 5.0 1 1

GroupAggregate (cost=150,668.94..150,675.29 rows=5 width=14) (actual time=20,425.269..20,425.270 rows=1 loops=1)

  • Group Key: trace0_.ontimestatus
2. 0.017 20,425.263 ↑ 839.0 1 1

Sort (cost=150,668.94..150,671.04 rows=839 width=22) (actual time=20,425.262..20,425.263 rows=1 loops=1)

  • Sort Key: trace0_.ontimestatus
  • Sort Method: quicksort Memory: 25kB
3. 0.012 20,425.246 ↑ 839.0 1 1

Hash Join (cost=94,291.46..150,628.20 rows=839 width=22) (actual time=20,341.385..20,425.246 rows=1 loops=1)

  • Hash Cond: (trace0_.ruleid = rule1_.uuid)
4. 19,595.352 20,424.796 ↑ 5,624.0 1 1

Bitmap Heap Scan on trace trace0_ (cost=94,166.12..150,488.01 rows=5,624 width=38) (actual time=20,340.938..20,424.796 rows=1 loops=1)

  • Recheck Cond: ((deliveryrequesteddate IS NOT NULL) AND (deliveryrequesteddate <= '2019-12-06 23:59:59'::timestamp without time zone) AND (deliveryrequesteddate >= '2019-06-09 00:00:00'::timestamp without time zone) AND (previousruleresultid IS NULL))
  • Filter: ((NOT errorflag) AND (processingmode = '2'::numeric) AND ((identifierkeyvalues = '2605603110'::text) OR (carrierreferencenumber = '2605603110'::text) OR (hashed SubPlan 1)) AND ((senderduns = ANY ('{BASF_AU01,BASF_AT01,BASF_PL01,BASF_KZ07,202108015,BASF_TR01,BASF_PE01,BASF_0050,BASF_DL01,899244198,BASF_BE05,BASF_DL07,BASF_CN0W,BASF_BR01,BASF_FR01,BASF_US01,315000554i,BASF_DE0E,BASF_EC01,BASF_SG02,BASF_DE0P,BASF_CA01,BASF_DE0M,BASF_CH01,BASF_MX01,315000554,370006132,BASF_VE02,"null",BASF_DE0S,BASF_DE0T,315000554ICO1,315000554ICO2,BASF_ES01,BASF_CL04,BASF_AE07,BASF_ZA01,343224259,BASF_AR01,BASF_UY01,BASF_CO04,BASF_IT01}'::text[])) OR (receiverduns = ANY ('{BASF_AU01,BASF_AT01,BASF_PL01,BASF_KZ07,202108015,BASF_TR01,BASF_PE01,BASF_0050,BASF_DL01,899244198,BASF_BE05,BASF_DL07,BASF_CN0W,BASF_BR01,BASF_FR01,BASF_US01,315000554i,BASF_DE0E,BASF_EC01,BASF_SG02,BASF_DE0P,BASF_CA01,BASF_DE0M,BASF_CH01,BASF_MX01,315000554,370006132,BASF_VE02,"null",BASF_DE0S,BASF_DE0T,315000554ICO1,315000554ICO2,BASF_ES01,BASF_CL04,BASF_AE07,BASF_ZA01,343224259,BASF_AR01,BASF_UY01,BASF_CO04,BASF_IT01}'::text[]))))
  • Rows Removed by Filter: 459207
  • Heap Blocks: exact=394937
5. 33.241 829.342 ↓ 0.0 0 1

BitmapAnd (cost=94,055.95..94,055.95 rows=14,580 width=0) (actual time=829.342..829.342 rows=0 loops=1)

6. 202.963 202.963 ↓ 9.2 637,540 1

Bitmap Index Scan on trace_deliveryrequesteddate_idx (cost=0.00..1,927.91 rows=69,078 width=0) (actual time=202.962..202.963 rows=637,540 loops=1)

  • Index Cond: ((deliveryrequesteddate IS NOT NULL) AND (deliveryrequesteddate <= '2019-12-06 23:59:59'::timestamp without time zone) AND (deliveryrequesteddate >= '2019-06-09 00:00:00'::timestamp without time zone))
7. 593.138 593.138 ↓ 1.1 3,550,686 1

Bitmap Index Scan on previousruleresultidindex_trace (cost=0.00..92,124.98 rows=3,142,989 width=0) (actual time=593.137..593.138 rows=3,550,686 loops=1)

  • Index Cond: (previousruleresultid IS NULL)
8.          

SubPlan (forBitmap Heap Scan)

9. 0.102 0.102 ↓ 0.0 0 1

Index Scan using "type_name_deliveryRequestedDate" on resultitem resultitem2_ (cost=0.56..110.11 rows=24 width=16) (actual time=0.101..0.102 rows=0 loops=1)

  • Index Cond: ((type = ANY ('{poNumber,deliveryNoteNumber,salesOrderNumber}'::text[])) AND (name = '2605603110'::text) AND (deliveryrequesteddate >= '2019-06-09 00:00:00'::timestamp without time zone) AND (deliveryrequesteddate <= '2019-12-06 23:59:59'::timestamp without time zone))
10. 0.050 0.438 ↑ 1.0 96 1

Hash (cost=124.12..124.12 rows=97 width=16) (actual time=0.437..0.438 rows=96 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 13kB
11. 0.388 0.388 ↑ 1.0 96 1

Seq Scan on rule rule1_ (cost=0.00..124.12 rows=97 width=16) (actual time=0.008..0.388 rows=96 loops=1)

  • Filter: ((eventmessagetype)::text = ANY ('{LoadTender,BookingRequest}'::text[]))
  • Rows Removed by Filter: 548
Planning time : 3.901 ms
Execution time : 20,427.965 ms