Skip to content

Instantly share code, notes, and snippets.

@emnlvrz
Created November 29, 2017 06:39
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save emnlvrz/5e53235c82260be011d84cf264e597e7 to your computer and use it in GitHub Desktop.
Save emnlvrz/5e53235c82260be011d84cf264e597e7 to your computer and use it in GitHub Desktop.
Seq Scan Plan
QUERY PLAN
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Hash Join (cost=55065.63..120421.32 rows=72750 width=16) (actual time=520.878..997.876 rows=72133 loops=1)
Hash Cond: (results.keyword_id = keywords.id)
Buffers: shared hit=26492 read=80492, temp read=2666 written=2636
-> Append (cost=0.00..60833.38 rows=72750 width=16) (actual time=0.078..320.196 rows=72133 loops=1)
Buffers: shared hit=26492 read=44417
-> Seq Scan on results (cost=0.00..0.00 rows=1 width=16) (actual time=0.007..0.007 rows=0 loops=1)
Filter: ((created_at >= '2017-10-25 00:00:00'::timestamp without time zone) AND (created_at <= '2017-11-10 23:59:59.999999'::timestamp without time zone) AND (account_id = 10026))
-> Index Scan using _hyper_1_37_chunk_account_id_created_at_idx on _hyper_1_37_chunk (cost=0.43..60833.38 rows=72749 width=16) (actual time=0.069..308.976 rows=72133 loops=1)
Index Cond: ((account_id = 10026) AND (created_at >= '2017-10-25 00:00:00'::timestamp without time zone) AND (created_at <= '2017-11-10 23:59:59.999999'::timestamp without time zone))
Buffers: shared hit=26492 read=44417
-> Hash (cost=43266.39..43266.39 rows=719139 width=8) (actual time=519.924..519.924 rows=718424 loops=1)
Buckets: 131072 Batches: 16 Memory Usage: 2789kB
Buffers: shared read=36075, temp written=2293
-> Seq Scan on keywords (cost=0.00..43266.39 rows=719139 width=8) (actual time=0.019..302.434 rows=718424 loops=1)
Buffers: shared read=36075
Planning time: 3.104 ms
Execution time: 1001.907 ms
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment