explain.depesz.com

PostgreSQL's explain analyze made readable

Result: sqda

Settings

Optimization(s) for this plan:

# exclusive inclusive rows x rows loops node
1. 1.637 28.637 ↓ 67.0 1,273 1

"Sort (cost=1,722.04..1,722.05 rows=19 width=553) (actual time=28.495..28.637 rows=1,273 loops=1)

  • Sort Key: t3._fld11372 DESC
  • Sort Method: quicksort Memory: 1340kB
2. 0.659 27.000 ↓ 67.0 1,273 1

Nested Loop Left Join (cost=425.25..1,721.87 rows=19 width=553) (actual time=7.973..27.000 rows=1,273 loops=1)

3. 1.350 25.068 ↓ 67.0 1,273 1

Nested Loop Left Join (cost=425.19..1,719.91 rows=19 width=568) (actual time=7.959..25.068 rows=1,273 loops=1)

  • Join Filter: ((t3._fld11371_type = '\\x08'::bytea) AND (t3._fld11371_rtref = '\\x00001a09'::bytea))
  • Filter: (NOT CASE WHEN ((t3._fld11371_type = '\\x08'::bytea) AND (t3._fld11371_rtref = '\\x00000094'::bytea)) THEN t5._marked WHEN ((t3._fld11371_type = '\\x08'::bytea) AND (t3._fld11371_rtref = '\\x00001a09'::bytea)) THEN t6._marked ELSE NULL::boolean END)
  • Rows Removed by Filter: 58
4. 1.321 19.725 ↓ 35.0 1,331 1

Hash Left Join (cost=425.07..1,635.77 rows=38 width=593) (actual time=3.976..19.725 rows=1,331 loops=1)

  • Hash Cond: (t5._fld2431rref = t7._idrref)
  • Filter: ((CASE WHEN ((t3._fld11371_type = '\\x08'::bytea) AND (t3._fld11371_rtref = '\\x00000094'::bytea)) THEN t7._fld7479rref ELSE NULL::bytea END = '\\xae3481d6573611a047506bb904eca628'::bytea) OR (CASE WHEN ((t3._fld11371_type = '\\x08'::bytea) AND (t3._fld11371_rtref = '\\x00000094'::bytea)) THEN t7._fld7479rref ELSE NULL::bytea END = '\\xa0c18456633ea55542e33953b8dfe48f'::bytea) OR (CASE WHEN ((t3._fld11371_type = '\\x08'::bytea) AND (t3._fld11371_rtref = '\\x00000094'::bytea)) THEN t7._fld7479rref ELSE NULL::bytea END = '\\x93d525eabb5f69da455f6d85f1bfc248'::bytea) OR (CASE WHEN ((t3._fld11371_type = '\\x08'::bytea) AND (t3._fld11371_rtref = '\\x00000094'::bytea)) THEN t7._fld7479rref ELSE NULL::bytea END = '\\xa26ead90d6601f084666e85f884e0740'::bytea))
  • Rows Removed by Filter: 163
5. 1.665 18.182 ↑ 1.3 1,494 1

Hash Right Join (cost=408.37..1,616.92 rows=1,902 width=613) (actual time=3.741..18.182 rows=1,494 loops=1)

  • Hash Cond: (t5._idrref = t3._fld11371_rrref)
  • Join Filter: ((t3._fld11371_type = '\\x08'::bytea) AND (t3._fld11371_rtref = '\\x00000094'::bytea))
6. 12.907 12.907 ↑ 1.0 3,435 1

Seq Scan on _reference148 t5 (cost=0.00..1,182.79 rows=3,435 width=41) (actual time=0.014..12.907 rows=3,435 loops=1)

  • Filter: (_fld450 = '0'::numeric)
7. 1.243 3.610 ↑ 1.3 1,494 1

Hash (cost=387.45..387.45 rows=1,902 width=592) (actual time=3.610..3.610 rows=1,494 loops=1)

  • Buckets: 2048 Batches: 1 Memory Usage: 948kB
8. 2.367 2.367 ↑ 1.3 1,494 1

Seq Scan on _reference11366 t3 (cost=0.00..387.45 rows=1,902 width=592) (actual time=0.031..2.367 rows=1,494 loops=1)

  • Filter: ((_fld450 = '0'::numeric) AND CASE WHEN ((_fld11372 >= '2018-01-01 00:00:00'::timestamp without time zone) AND (_fld11372 <= '2019-03-13 23:59:59'::timestamp without time zone)) THEN true ELSE false END)
  • Rows Removed by Filter: 2192
9. 0.067 0.222 ↑ 1.0 259 1

Hash (cost=13.85..13.85 rows=259 width=40) (actual time=0.222..0.222 rows=259 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 24kB
10. 0.155 0.155 ↑ 1.0 259 1

Seq Scan on _reference144 t7 (cost=0.00..13.85 rows=259 width=40) (actual time=0.008..0.155 rows=259 loops=1)

  • Filter: (_fld450 = '0'::numeric)
11. 3.993 3.993 ↓ 0.0 0 1,331

Index Scan using _reference6665hpk on _reference6665 t6 (cost=0.11..2.20 rows=1 width=21) (actual time=0.003..0.003 rows=0 loops=1,331)

  • Index Cond: ((_fld450 = '0'::numeric) AND (t3._fld11371_rrref = _idrref))
12. 1.273 1.273 ↓ 0.0 0 1,273

Index Scan using _inforg11308_bydims on _inforg11308 t4 (cost=0.06..0.10 rows=1 width=34) (actual time=0.001..0.001 rows=0 loops=1,273)

  • Index Cond: ((_fld450 = '0'::numeric) AND (_fld11309rref = '\\x9de208606e710c9511e34d15c4a8ae2b'::bytea) AND (_fld11377rref = t3._idrref))
Planning time : 3.446 ms
Execution time : 28.894 ms