explain.depesz.com

PostgreSQL's explain analyze made readable

Result: ir65

Settings
# exclusive inclusive rows x rows loops node
1. 0.004 143.208 ↑ 1.0 3 1

Limit (cost=1.73..8.44 rows=3 width=203) (actual time=143.194..143.208 rows=3 loops=1)

2. 0.004 143.204 ↑ 411,074.0 3 1

Nested Loop Left Join (cost=1.73..2,755,306.28 rows=1,233,222 width=203) (actual time=143.193..143.204 rows=3 loops=1)

3. 0.001 143.152 ↑ 411,074.0 3 1

Nested Loop Anti Join (cost=1.59..2,555,009.98 rows=1,233,222 width=195) (actual time=143.144..143.152 rows=3 loops=1)

  • Join Filter: (lv2.rowid = "LogEvent_1".rowid)
4. 0.007 143.112 ↑ 411,076.3 3 1

Nested Loop Left Join (cost=1.46..2,370,019.06 rows=1,233,229 width=195) (actual time=143.106..143.112 rows=3 loops=1)

  • Filter: (("TagHeader".rowid IS NULL) OR "TagHeader".active)
5. 0.005 143.096 ↑ 586,414.0 3 1

Merge Append (cost=1.04..1,551,367.14 rows=1,759,242 width=159) (actual time=143.093..143.096 rows=3 loops=1)

  • Sort Key: "LogEvent_1"."time" DESC
6. 124.295 124.295 ↓ 0.0 0 1

Index Scan Backward using "LogEvent_1_time_idx" on "LogEvent_1" (cost=0.29..8,427.40 rows=310 width=179) (actual time=124.295..124.295 rows=0 loops=1)

  • Index Cond: ("time" >= '1561939200000'::bigint)
  • Filter: (("tagHeader" = ANY ('{83290,1507,149028,334785,115878,214452,165380,230801,269224,285588,198210,247286,132650,285582,165491,285570,50436,50557,1475,181832,1472,334637,83128,165475,230909,198059,383830,230899,66903,132624,269193,149107,1331,165456,99466,269189,214404,181681,66747,394452,165454,149094,198025,165445,1304,367427,181659,50499,83082,132713,83080,301864,99572,83081,50500,132716,247086,99560,367294,165291,50365,269277,198129,132699,149063,148923,115908,34114,230709,181754,148913,66701,230690,181757,165258,181731,334663,33965,17734,394246,1372,33959,165375,181720,165363,334514,269094,50308,230656,181718,269086,197937,334510,214301,285567,247141,33931}'::bigint[])) OR ("tagHeader" IS NULL))
  • Rows Removed by Filter: 46222
7. 8.691 8.691 ↑ 1,458.0 1 1

Index Scan Backward using "LogEvent_2_time_idx" on "LogEvent_2" (cost=0.29..8,275.97 rows=1,458 width=177) (actual time=8.691..8.691 rows=1 loops=1)

  • Index Cond: ("time" >= '1561939200000'::bigint)
  • Filter: (("tagHeader" = ANY ('{83290,1507,149028,334785,115878,214452,165380,230801,269224,285588,198210,247286,132650,285582,165491,285570,50436,50557,1475,181832,1472,334637,83128,165475,230909,198059,383830,230899,66903,132624,269193,149107,1331,165456,99466,269189,214404,181681,66747,394452,165454,149094,198025,165445,1304,367427,181659,50499,83082,132713,83080,301864,99572,83081,50500,132716,247086,99560,367294,165291,50365,269277,198129,132699,149063,148923,115908,34114,230709,181754,148913,66701,230690,181757,165258,181731,334663,33965,17734,394246,1372,33959,165375,181720,165363,334514,269094,50308,230656,181718,269086,197937,334510,214301,285567,247141,33931}'::bigint[])) OR ("tagHeader" IS NULL))
  • Rows Removed by Filter: 77
8. 10.105 10.105 ↑ 585,824.7 3 1

Index Scan Backward using "LogEvent_3_time_idx" on "LogEvent_3" (cost=0.44..1,511,925.87 rows=1,757,474 width=159) (actual time=10.103..10.105 rows=3 loops=1)

  • Index Cond: ("time" >= '1561939200000'::bigint)
  • Filter: (("tagHeader" = ANY ('{83290,1507,149028,334785,115878,214452,165380,230801,269224,285588,198210,247286,132650,285582,165491,285570,50436,50557,1475,181832,1472,334637,83128,165475,230909,198059,383830,230899,66903,132624,269193,149107,1331,165456,99466,269189,214404,181681,66747,394452,165454,149094,198025,165445,1304,367427,181659,50499,83082,132713,83080,301864,99572,83081,50500,132716,247086,99560,367294,165291,50365,269277,198129,132699,149063,148923,115908,34114,230709,181754,148913,66701,230690,181757,165258,181731,334663,33965,17734,394246,1372,33959,165375,181720,165363,334514,269094,50308,230656,181718,269086,197937,334510,214301,285567,247141,33931}'::bigint[])) OR ("tagHeader" IS NULL))
9. 0.009 0.009 ↓ 0.0 0 3

Index Scan using "TagHeader_pkey" on "TagHeader" (cost=0.42..0.46 rows=1 width=9) (actual time=0.003..0.003 rows=0 loops=3)

  • Index Cond: ("LogEvent_1"."tagHeader" = rowid)
10. 0.013 0.039 ↓ 0.0 0 3

Materialize (cost=0.13..6.59 rows=10 width=8) (actual time=0.013..0.013 rows=0 loops=3)

11. 0.001 0.026 ↓ 0.0 0 1

Append (cost=0.13..6.54 rows=10 width=8) (actual time=0.026..0.026 rows=0 loops=1)

12. 0.011 0.011 ↓ 0.0 0 1

Index Only Scan using "logEvent_1_GOOSEIndex" on "LogEvent_1" lv2 (cost=0.13..2.14 rows=1 width=8) (actual time=0.011..0.011 rows=0 loops=1)

  • Heap Fetches: 0
13. 0.008 0.008 ↓ 0.0 0 1

Index Only Scan using "logEvent_2_GOOSEIndex" on "LogEvent_2" lv2_1 (cost=0.13..2.14 rows=1 width=8) (actual time=0.008..0.008 rows=0 loops=1)

  • Heap Fetches: 0
14. 0.006 0.006 ↓ 0.0 0 1

Index Only Scan using "logEvent_3_GOOSEIndex" on "LogEvent_3" lv2_2 (cost=0.13..2.21 rows=8 width=8) (actual time=0.006..0.006 rows=0 loops=1)

  • Heap Fetches: 0
15. 0.048 0.048 ↑ 1.0 1 3

Index Scan using "LogEventClass_pkey" on "LogEventClass" (cost=0.14..0.16 rows=1 width=16) (actual time=0.016..0.016 rows=1 loops=3)

  • Index Cond: ("LogEvent_1"."eventClass" = rowid)
Planning time : 466.478 ms