PDA

View Full Version : FTS: No results for "spanish e" but for "spanish ey"



dolodobendan
2018-09-17, 14:02
What the title says and the pictures show:

25657

25658

Is this the intended behavior (because e is too short?) I would expect results to become less, not more, when tightening the search parameters. (Just wondering, not complaining. :p )

mherger
2018-09-17, 21:12
> What the title says and the pictures show:

And when I saw the title without the screenshots I was wondering what
the "spanish ey" character was :-).

> Is this the intended behavior (because e is too short?)

Don't know, really. I do indeed see in server.log that it would do the
following (set plugin.fulltext to debug):

Search token (track): 'TONY* AND LE*'
Search token (track): 'TONY* AND L'

Must be some optimization gone wrong.

--

Michael

mherger
2018-09-17, 22:05
https://github.com/Logitech/slimserver/blob/public/7.9/Slim/Plugin/FullTextSearch/Plugin.pm#L256

We do indeed optimize the single character case out. Most likely there
were performance due to too many results. But then I wonder why this
would happen when there is another token. You'd think that would be less
result than a single token only. Hmm...
--

Michael

DJanGo
2018-09-17, 22:35
https://github.com/Logitech/slimserver/blob/public/7.9/Slim/Plugin/FullTextSearch/Plugin.pm#L256

We do indeed optimize the single character case out.

hmm
but there is a difference
searching for "spanish G" founds all my spanish guitars.
searching for "spanish v" shows spanish fly from Van Halen.

mherger
2018-09-18, 02:12
> but there is a difference
> searching for "spanish G" founds all my spanish guitars.
> searching for "spanish v" shows spanish fly from Van Halen.

What build? I tweaked the behaviour earlier today.

--

Michael

DJanGo
2018-09-18, 02:33
What build? I tweaked the behaviour earlier today.

--

Michael

Ahh ;-)

on 7.9.2 - 1537254228 @ Tue Sep 18 09:16:24 CEST 2018 deb64 "spanish e" shows Spanish Eyes ;-)
Well done Michael:o

dolodobendan
2018-09-18, 05:42
And when I saw the title without the screenshots I was wondering what
the "spanish ey" character was :-).


:D



We do indeed optimize the single character case out. Most likely there
were performance due to too many results. But then I wonder why this
would happen when there is another token. You'd think that would be less
result than a single token only. Hmm...


That's what got me wondering.



I tweaked the behaviour earlier today.
Michael

That was scary fast. Thank you!

dolodobendan
2018-09-18, 05:48
Ahh ;-)

on 7.9.2 - 1537254228 @ Tue Sep 18 09:16:24 CEST 2018 deb64 "spanish e" shows Spanish Eyes ;-)
Well done Michael:o

I can confirm this, too. Well done, indeed!