Can't search for phrases, only single words


(5d361d2e Ff9c.4c44.9966.ea42d4) #1

Search for “The Well” finds discussions containing the word “well” and not “The Well”. Search for “Open ID” finds discussions containing the word “open” and not “Open ID”.


(Daniel Hölbling) #2

As far as I can tell from looking at the code at the moment all the search features are powerd by Postgres ability to search through the tables.

I guess it makes sense to not require Lucene or some “real” search engine to run as you already require users to run Postgres and Redis for Discourse to run, but in the long run a better search (maybe through a plugin) powered by Lucene or something would be desirable…
It may be also prudent to check if the Postgres guys don’t already have a decent full-text search that can do comprehensive search.


(Sam Saffron) #3

The is a stop word

We can look at making the search a bit smarter for cases like this, but our standard implementation simply strips it.


(Jeff Atwood) #4

I dunno, I can’t find your post using a phrase search of "standard implementation" either:

Because your post contains that exact phrase, I would expect to see this topic in that list, if quoted phrase searching was working… perhaps we should add this to the list @eviltrout, I don’t see why this shouldn’t work, personally.


(Jeff Atwood) #5

Just as a reminder @sam as you were the last to work on this, I do think quoted phrases should work in search, maybe for 1.2?


(Sam Saffron) #6

Yeah it’s not implemented at the moment, stemming makes it extra complicated, we would need to carry an extra index for exact matches


(Jeff Atwood) #7

Still want “quoted phrase” to work In search.


(Jeff Atwood) #8

Just an update, quoted phrase search now works thanks to some improvements by @sam


(Jeff Atwood) #9