-
Notifications
You must be signed in to change notification settings - Fork 55
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support indexing tsquery phrases #43
Comments
On Thu, Jul 19, 2018 at 5:43 PM, Felix Bünemann ***@***.***> wrote:
Currently indexing with rum fails, if the tsquery column or expression
contains phrases:
ERROR: Indexing of phrase tsqueries isn't supported yet
It would be very useful if this feature was supported, since it would
allow to quickly check if a phrase is contained in some text (for example
to filter text containing blacklisted phrases).
please, provide us more information. Exact create index would be enough
… —
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#43>, or mute the thread
<https://github.com/notifications/unsubscribe-auth/AGFI4tIJU_saAx5Mte_mNE6sSphcryxAks5uIJstgaJpZM4VWiGI>
.
--
Postgres Professional: http://www.postgrespro.com
The Russian Postgres Company
|
CREATE TABLE phrases (phrase tsquery);
INSERT INTO phrases (to_tsquery('simple', 'quick <-> red <-> fox'));
CREATE INDEX phrases_idx on phrases using RUM (phrase);
-- ERROR: Indexing of phrase tsqueries isn't supported yet |
The easiest thing, which is possible to do here, is to support phrase operator in the same way as AND operator. That would require to check actual phrase matching using heap tuple during recheck stage. But it appears that our format of additional info didn't have reserved area in order to store whether recheck is needed. I'll investigate what could be done in this area. |
I think a recheck would be perfectly fine. Thanks for looking into it! |
Currently indexing with rum fails, if the tsquery column or expression contains phrases:
It would be very useful if this feature was supported, since it would allow to quickly check if a phrase is contained in some text (for example to filter text containing blacklisted phrases).
The text was updated successfully, but these errors were encountered: