explain.depesz.com

A tool for finding a real cause for slow queries.

Result: IXb : EdTest

options
Did it help? Consider supporting us - Bitcoin address: 12v2hUztAk2LgzQ9H9LMwuU32urHMjZQnq
# exclusive inclusive rows x rows loops node
1. 0.007 4264.499 ↓ 7.0 7 1

Subquery Scan on vw_getcurrentprimaryattribute (cost=53832.78..53832.79 rows=1 width=885) (actual time=4264.493..4264.499 rows=7 loops=1)

2. 0.049 4264.492 ↓ 7.0 7 1

Sort (cost=53832.78..53832.78 rows=1 width=889) (actual time=4264.491..4264.492 rows=7 loops=1)

  • Sort Key: ama.activemachineid, ama.attributesequence
  • Sort Method: quicksort Memory: 25kB
3. 0.050 4264.443 ↓ 7.0 7 1

Nested Loop Left Join (cost=53655.96..53832.77 rows=1 width=889) (actual time=4263.948..4264.443 rows=7 loops=1)

  • Join Filter: ((ama.activemachineid = raw1.activemachineid) AND ((ama.attributeaddress)::text = (raw1.attributeaddress)::text))
4. 0.077 0.077 ↓ 7.0 7 1

Seq Scan on tblt_activemachineattributes ama (cost=0.00..1.09 rows=1 width=874) (actual time=0.068..0.077 rows=7 loops=1)

  • Filter: (attributeisprimary = 1)
5. 0.196 4264.316 ↓ 7.0 7 7

Nested Loop (cost=53655.96..53831.65 rows=1 width=24) (actual time=609.131..609.188 rows=7 loops=7)

  • Join Filter: ((raw1.activemachineid = raw.activemachineid) AND ((raw1.attributeaddress)::text = (raw.attributeaddress)::text))
6. 0.054 4263.777 ↑ 3.0 7 7

Sort (cost=53655.96..53656.01 rows=21 width=17) (actual time=609.110..609.111 rows=7 loops=7)

  • Sort Key: raw.activemachineid, raw.attributeaddress
  • Sort Method: quicksort Memory: 25kB
7. 985.944 4263.723 ↑ 3.0 7 1

HashAggregate (cost=53655.29..53655.50 rows=21 width=17) (actual time=4263.718..4263.723 rows=7 loops=1)

8. 1026.029 3277.779 ↑ 1.0 625922 1

Merge Join (cost=1.41..48960.88 rows=625922 width=17) (actual time=0.037..3277.779 rows=625922 loops=1)

  • Merge Cond: (raw.rawattributeid = aok.rawattributeid)
9. 1098.521 1098.521 ↑ 1.0 625929 1

Index Scan using rawattributeid_pk on tblt_attributes_raw raw (cost=0.00..20531.26 rows=625929 width=21) (actual time=0.021..1098.521 rows=625929 loops=1)

10. 1153.229 1153.229 ↑ 1.0 625922 1

Index Scan using valraw on tblt_attributes_validated aok (cost=0.00..19042.15 rows=625922 width=4) (actual time=0.011..1153.229 rows=625922 loops=1)

11. 0.343 0.343 ↑ 1.0 1 49

Index Scan using rawattribtime on tblt_attributes_raw raw1 (cost=0.00..8.34 rows=1 width=24) (actual time=0.007..0.007 rows=1 loops=49)

  • Index Cond: (attributetimestamp = (max(raw.attributetimestamp)))