Meta Stack Exchange is where users like you discuss bugs, features, and support issues that affect the software powering all 158 Stack Exchange communities.

What is meta?
Here's how it works:
  1. Any Stack Exchange user can ask a question
  2. The community provides support, votes on ideas, and reports bugs
  3. Your voice helps shape the way Stack Exchange operates

As I see search terms in Search used with OR operator by default and I see no way to switch or force it to AND. For example I just queried [XTS mode] in the stackoverflow and all results were irrelevant (the moment before I read a post where both terms were used)

Google always used AND operator by default. As I recall from my experience the noticeable exception is phpBB that uses OR by default. I know that this can be a very long discussion, but the well-known search engines is a strong point on my side, aren't they?

EDIT: I just read about the feature that AND results should be at top. Not always actually, or with this approach (all shown, AND first), suggestion would be at least mark the sections, so to see there's no AND results at all.

I'd say that the search works strangely, two examples:

share|improve this question
up vote 3 down vote accepted

The new elasticsearch-backed search is using an AND operator by default now.

share|improve this answer
Looks very promising, thanks – Maksee Jan 9 '13 at 7:18
In fact I can't find a way to use an OR operator with the new elasticsearch for those times I do want it )-: – hippietrail Jan 13 '13 at 1:07
Any OR operator left? The once documented [or] no longer seems to work: Zero search results when searching for [tagOne] [or] [tagTwo]. – Arjan Jan 27 '13 at 16:27

I agree. The default OR search is a complete violation of web design guidelines. If the results returned do not include all the terms searched for, this should be communicated to the user in some way.

share|improve this answer

This is now implemented in a simpler way; just begin each word with a + if it must appear in your results, eg:

+apples +oranges

share|improve this answer
Jeff, that's probably a "good enough" solution for StackOverflow users, but what about, say, Cooking users? When was the last time a real search engine required users to use + to do an AND search? 1998? Why not just make all search AND, period? – devuxer Mar 5 '12 at 19:32

I agree. My logic is this:

  • Google uses "and", not "or".
  • The vast majority of Internet search goes through Google.
  • Therefore, you should have an extremely good reason for not working like Google does.

Using "or" just confuses people. Having a workaround that allows "and" but isn't documented on the search tips page confuses people even more.

Jeff, could you at least add your answer above to the tips page, please?

share|improve this answer

Yes, I find this strange as well.

As a work around, you might be interested to know that you can do AND searches if you edit the URL directly:

Will return all questions matching both python and optimization.

share|improve this answer
Hmm, the general query in my case produces exactly the same query with pluses, i.e. "wrong" query already has pluses so I don't know what to change in order to get right results :) – Maksee Sep 17 '09 at 14:28
Have you double checked the entire url? When I type "python optimization" into the search box, I get: This is not the same as the URL in my answer (my url is not a search). – ire_and_curses Sep 17 '09 at 14:43
@ire and curses, the URL in your answer is searching for questions tagged both python and optimization, the URL in the comment searches for posts tagged Python and containing the text optimization. StackOverflow automatically changes some search keywords to search based on tags, (… towards the end of the post) – Nathan Koop Sep 17 '09 at 15:14
@Nathan Koop: Thanks for the clarification. I realise I misunderstood the OP - he is talking about string searches, not tag searches, although he uses the same square bracket syntax in his question. There is no XTS tag on SO. "[Delphi] register" works for the second example – ire_and_curses Sep 17 '09 at 15:47

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .