-
Notifications
You must be signed in to change notification settings - Fork 95
Add suport for TEXT[] types when creating bm25 index #199
Copy link
Copy link
Open
Labels
enhancementNew feature or requestNew feature or request
Description
Problem Statement
The array_to_string(ARRAY, text, [ text) is not immutable and can't be used as source for indexes.
It's very common to use TEXT[] and not TEXT for large text content because each separation \n represents an element of the array.
Proposed Solution
CREATE INDEX docs_bm25_idx ON docs
USING bm25(array_to_string(content, ' ')) -- working!
WITH (text_config='spanish');
-- OR
CREATE INDEX docs_bm25_idx ON docs
USING bm25(content) -- row as text[]
WITH (text_config='spanish');
Alternatives Considered
Paradedb actually supports the use case.
Additional Context
pg_textsearch v0.5.0
postgresql v18.1
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request