From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Andreas Seltenreich <seltenreich(at)gmx(dot)de> |
Cc: | pgsql-hackers(at)postgresql(dot)org, Oleg Bartunov <obartunov(at)gmail(dot)com>, Teodor Sigaev <teodor(at)sigaev(dot)ru> |
Subject: | Re: [sqlsmith] FailedAssertion("!(k == indices_count)", File: "tsvector_op.c", Line: 511) |
Date: | 2016-08-03 21:52:44 |
Message-ID: | 20542.1470261164@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
I wrote:
> I'm thinking there are two distinct bugs here.
Actually, make that three bugs. I was so focused on the crashing
that I failed to notice that ts_delete wasn't producing sane answers
even when it didn't crash:
regression=# select ts_delete(array_to_tsvector('{smith,foo,bar}'::text[]), '{smith,smith}'::text[]);
ts_delete
---------------------
'smith' 'foo' 'bar'
(1 row)
regression=# select ts_delete(array_to_tsvector('{smith,foo,bar}'::text[]), '{smith,foo}'::text[]);
ts_delete
---------------
'smith' 'bar'
(1 row)
regression=# select ts_delete(array_to_tsvector('{smith,foo,bar}'::text[]), '{bar,smith}'::text[]);
ts_delete
---------------------
'smith' 'foo' 'bar'
(1 row)
The non-array version is no better:
regression=# select ts_delete(array_to_tsvector('{smith,foo,bar}'::text[]), 'smith'::text);
ts_delete
---------------------
'smith' 'foo' 'bar'
(1 row)
regression=# select ts_delete(array_to_tsvector('{smith,foo,bar}'::text[]), 'foo'::text);
ts_delete
---------------
'smith' 'bar'
(1 row)
regression=# select ts_delete(array_to_tsvector('{smith,foo,bar}'::text[]), 'bar'::text);
ts_delete
---------------------
'smith' 'foo' 'bar'
(1 row)
I'm not sure if ts_delete takes its second argument as verbatim lexemes
or normalizes them first, but none of these words are changed by
to_tsvector, so either way it seems to fail to delete stuff it should.
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Thomas Munro | 2016-08-03 21:53:16 | Re: [sqlsmith] FailedAssertion("!(k == indices_count)", File: "tsvector_op.c", Line: 511) |
Previous Message | Tom Lane | 2016-08-03 21:39:36 | Re: [sqlsmith] FailedAssertion("!(k == indices_count)", File: "tsvector_op.c", Line: 511) |