New search capabilities available: phrases, excluding terms, alternatives ("or")
On Sunday, I took the site down for a short downtime to upgrade the database from PostgreSQL version 10 to 12. One of the main reasons I wanted to do that upgrade was to get access to a new search...
On Sunday, I took the site down for a short downtime to upgrade the database from PostgreSQL version 10 to 12. One of the main reasons I wanted to do that upgrade was to get access to a new search function, and I've updated to using it now, so we have multiple nice new search capabilities available.
These should all be pretty familiar since a lot of other search systems and search engines have similar capabilities with the same syntax:
- As before, by default, searching for multiple words will be treated as "all of these terms". So if you search ~games for steam play, you'll get all topics that have both "steam" and "play" in them.
- Phrases can now be searched for by putting double quotes around them. Searching ~games for "steam play" in quotes will only find topics that specifically have "steam play".
- Excluding terms can be done by putting a minus sign in front of it. For example, if you wanted to try to find ~games posts about Blizzard and exclude the recent China controversy, you could search for blizzard -china.
- Alternatives can be searched for by using "or". This changes to "any of these terms" instead of "all of these terms". For example, searching for overwatch or diablo will find any topic with either of those terms, instead of both.
- These capabilities can be combined, so you can exclude phrases, use "or" with phrases, and so on. For example: blizzard -"hong kong" or diablo.
This all works both through the main site topic search (at the top of the sidebar) as well as the new search for your own topics/comments.
I'm going to write a page for the Docs with info about these capabilities, but I think I want to try to find a full specification of what's supported first to make sure I cover it properly. The PostgreSQL docs are pretty vague about it, so I'll probably need to take a look in the actual code.
Please let me know if you notice any issues with it, or if anything's confusing that I should make sure to document.
And as usual, I've given everyone 10 invites, accessible on the invite page.