explain.depesz.com

PostgreSQL's explain analyze made readable

Result: sDb2 : Optimization for: plan #9tx8

Settings

Optimization path:

Optimization(s) for this plan:

# exclusive inclusive rows x rows loops node
1. 0.003 0.543 ↑ 1.0 1 1

Result (cost=9.72..9.73 rows=1 width=8) (actual time=0.543..0.543 rows=1 loops=1)

2.          

Initplan (forResult)

3. 0.001 0.540 ↑ 1.0 1 1

Limit (cost=0.56..9.72 rows=1 width=8) (actual time=0.540..0.540 rows=1 loops=1)

4. 0.539 0.539 ↑ 143.0 1 1

Index Scan Backward using idx_token_user_id_desc on token (cost=0.56..1,309.56 rows=143 width=8) (actual time=0.539..0.539 rows=1 loops=1)

  • Index Cond: ((user_id = 819975) AND (id IS NOT NULL))
  • Filter: ((expired IS NOT TRUE) AND (expiration > '2018-12-28 12:31:24.265'::timestamp without time zone) AND ((type)::text <> 'ADMIN'::text))