0
votes

The Underscore '_' works like an AND, doesn't it?

When searching for any of

test_12 , 12_test , 12 AND test , test AND 12

I get the same hit.

But why is there a problem with the wildcard?

mytest* AND abc_IN_CRM_C  --> finds results!
abc_IN_CRM_C_mytest* --> no results!
abc_IN_CRM_C AND mytest* --> results ?!

What am I doing wrong?

1

1 Answers

0
votes

If you are using the StandardAnalyzer, then the text is split on underscores. That's why you get the same results as using "AND".

Also see Lucene search and underscores