Skip to content
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

SQL statement runs infinitely #66

Open
degtyaryov opened this issue Oct 2, 2019 · 0 comments
Open

SQL statement runs infinitely #66

degtyaryov opened this issue Oct 2, 2019 · 0 comments

Comments

@degtyaryov
Copy link

degtyaryov commented Oct 2, 2019

Hello!

Experimented with RUM.

Purely by chance, I created a table:

CREATE TABLE test
(
    tsvector1 tsvector,
    tsvector2 tsvector
);

Insert data into it:

INSERT INTO test(tsvector1, tsvector2)
SELECT to_tsvector('russian'::regconfig, 'тест '||s), to_tsvector('english'::regconfig, 'test '||s)
FROM generate_series(1, 1000000) s;

Created an index:

CREATE INDEX idx_test_rum
ON test
USING rum (tsvector1, tsvector2);

Run the SQL statement:

SELECT  *,
        tsvector1 <=> plainto_tsquery('russian'::regconfig, 'тест') as rank1,
        tsvector2 <=> plainto_tsquery('english'::regconfig, 'test') as rank2
FROM test
WHERE  tsvector1 @@ plainto_tsquery('russian'::regconfig, 'тест')
ORDER BY rank1, rank2
LIMIT 1000;

SQL statement runs infinitely!

Query is not canceled by pg_cancel_backend and disconnect client.
Unable to stop server PostgreSQL.

Only kill -SIGKILL.

I check this on PostgreSQL 10 and PostgreSQL 12.
RUM latest release 1.3.6 and latest commit e34375a.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant