Skip to content

Instantly share code, notes, and snippets.

@teburd
Created May 10, 2013 17:23
Show Gist options
  • Save teburd/5555930 to your computer and use it in GitHub Desktop.
Save teburd/5555930 to your computer and use it in GitHub Desktop.
seq scan horrible
drake=# explain analyze select id from vertices where name_fts @@ plainto_tsquery('school') or description_fts @@ plainto_tsquery('school') limit 100;
QUERY PLAN
-------------------------------------------------------------------------------------------------------------------------
Limit (cost=0.00..201.42 rows=100 width=16) (actual time=53.723..356.704 rows=100 loops=1)
-> Seq Scan on vertices (cost=0.00..9031.60 rows=4484 width=16) (actual time=53.721..356.685 rows=100 loops=1)
Filter: ((name_fts @@ plainto_tsquery('school'::text)) OR (description_fts @@ plainto_tsquery('school'::text)))
Rows Removed by Filter: 93311
Total runtime: 356.751 ms
(5 rows)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment