Support tsvector columns for Postgres fulltext search
See original GitHub issueProblem
See https://github.com/prisma/prisma/issues/8950#issuecomment-1067395682 a search runs 1,000x faster with a tsvector
column with an index, when compared to the “TEXT” field with an GIN index approach you currently recommend (which does not use the index due to the bug linked)
Suggested solution
Support tsvector
columns
Alternatives
None
Additional context
n/a
Issue Analytics
- State:
- Created 2 years ago
- Reactions:3
- Comments:6
Top Results From Across the Web
Documentation: 15: 12.2. Tables and Indexes - PostgreSQL
It is possible to do a full text search without an index. ... ALTER TABLE pgweb ADD COLUMN textsearchable_index_col tsvector GENERATED ALWAYS AS ......
Read more >Full Text Searching with Postgres | Forestry.io
Postgres has a data type called tsvector that is used for full text search. A tsvector value merges different variants of the same...
Read more >Postgres Full-Text Search: A Search Engine in a Database
A document is a set of data on which you want to carry out your full-text search. In Postgres, this could be built...
Read more >Mastering PostgreSQL Tools: Full-Text Search and Phrase ...
full-text search refers to techniques for searching a single ... all of this (notice the tsvector data type for the document_tokens column):
Read more >Probing Text Data Using PostgreSQL Full-Text Search - Arctype
Learn how to leverage the power of full-text search in PostgreSQL to search through ... By now, we know that the tsvector is...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Here’s the workaround I used for now:
Performance is 🔥 :
Compared to what Prisma does, with it’s “preview fulltext search” module. 214x slower.
That’s actually one of my proposed solution, using a tsvector stored generated column from one or more column + index
https://github.com/prisma/prisma/issues/8950#issuecomment-982915628