The following bug has been logged on the website:
Bug reference: 15689
Logged by: Ivan Viragine
Email address: ivanviragine@gmail.com
PostgreSQL version: 10.3
Operating system: MacOS and centOS
Description:
When using to_tsquery function it is stemming negation/not parts of the
query, where it probably shouldn't.
Some examples:
SELECT to_tsquery('english', 'car & !cars');
to_tsquery
----------------
'car' & !'car'
SELECT to_tsquery('english', 'corporation & !corporative');
to_tsquery
----------------------
'corpor' & !'corpor'
IMHO, it shouldn't stem cars to car, neither corporative to corpor. There
are several examples where it could lead to incorrect results.