Hi!

As per jira-LUCENE-7932 discussions I am sending this mail along with my java 
code(LuceneQueryTest.java class: attached) calling Lucene code.


A.      Code structure:
Attached sample code(LuceneQueryTest.java class) consists of 4 steps:

1.       Create index (Needed to be executed only once to insert records)

2.       Prepare query parameters

3.       Prepare QueryParser object

4.       Search and display results



B.      Analysis Report:

Step 1 can be executed only once because it creates index files first time and 
then it can be commented.

Step 2 has 3 cases

Case a) queryParams = "LocationCode:1 AND Category:a";

                Test analysis: When we execute this query all records are 
fetched, even though we don't have records of Category=a. (Not working)

                [cid:[email protected]]



Case b) queryParams = "LocationCode:1 AND Category:A";

                Test analysis: When we execute this query all records are 
fetched, even though we don't have records of Category=A. (Not working)

[cid:[email protected]]



Case c) queryParams = "LocationCode:1 AND Category:a*"; (Works Fine)

                Test analysis: When we execute this query No records are 
fetched, this works fine.

                [cid:[email protected]]

C.      Submission to lucene development team:

Looking at case a) and case b) I think there is bug in Lucene 
IndexSearcher.java or IndexReader.java in LuceneCore module.

I used both Lucene 5.3 and latest version Lucene 6.6 to reproduce issue. I 
found same results.



If you need more information, please let me know.


Best regards,
Rohit


Attachment: LuceneQueryTest.java
Description: LuceneQueryTest.java

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to