explain.depesz.com

PostgreSQL's explain analyze made readable

Result: hwCj

Settings
# exclusive inclusive rows x rows loops node
1. 482.910 4,722.067 ↑ 1.1 167,072 1

GroupAggregate (cost=733,100.03..739,328.28 rows=177,909 width=108) (actual time=4,101.802..4,722.067 rows=167,072 loops=1)

  • Group Key: (to_char(date_trunc('month'::text, ""timestamp""), 'YYYY-MM-DD'::text)), team, user_id, company, query
2. 2,547.285 4,239.157 ↓ 2.6 465,039 1

Sort (cost=733,100.03..733,544.98 rows=177,981 width=92) (actual time=4,101.757..4,239.157 rows=465,039 loops=1)

  • Sort Key: (to_char(date_trunc('month'::text, ""timestamp""), 'YYYY-MM-DD'::text)), team, user_id, company, query
  • Sort Method: quicksort Memory: 77547kB
3. 199.146 1,691.872 ↓ 2.6 465,039 1

Gather (cost=1,000.00..717,578.87 rows=177,981 width=92) (actual time=0.450..1,691.872 rows=465,039 loops=1)

  • Workers Planned: 6
  • Workers Launched: 6
4. 1,492.726 1,492.726 ↓ 2.2 66,434 7

Parallel Seq Scan on server (cost=0.00..698,039.19 rows=29,664 width=92) (actual time=0.074..1,492.726 rows=66,434 loops=7)

  • Filter: ((team <> 'A Team'::text) AND (""timestamp"" >= '2018-01-01 00:00:00'::timestamp without time zone) AND (""timestamp"" <= '2019-03-01 00:00:00'::timestamp without time zone) AND (user_id <> ALL ('{u1,u2,u3,u4,u5}'::text[])))
  • Rows Removed by Filter: 280933