1

I want to know how lucene find documents matching a boolean query like this: "+a +b c", I mean what's its algorithm?

Thanks

Shahryar
  • 1,454
  • 2
  • 15
  • 32

2 Answers2

1
  1. Similarity
  2. Lucene Theory
Xodarap
  • 11,581
  • 11
  • 56
  • 94
1

Please check Apache Lucene - Query Parser Syntax. It helped me to understand the algorithm

  • "+a +b c" means that you are searching for documents that MUST contain "a" AND MUST contain "b" and MIGHT contain "c" --> For example the matches are: "b a", "a b c", "wkfkjwfk32 a b", "kj2h4rkj2 a kjhgkk b" in any order [a and b are required, and c is optional]
Roxanne
  • 85
  • 7