You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@solr.apache.org by "David Smiley (Jira)" <ji...@apache.org> on 2022/11/01 15:36:00 UTC

[jira] [Resolved] (SOLR-16514) lucene query: only QueryParser run well

     [ https://issues.apache.org/jira/browse/SOLR-16514?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

David Smiley resolved SOLR-16514.
---------------------------------
    Resolution: Invalid

Hello.  You filed this issue for the Solr project but it appears it should have been for Lucene?  I have the ability to move/migrate the issue over there, but I think you should instead use a project mailing list to ask questions.  Both Lucene & Solr (and maybe all ASF projects) don't use Jira for questions.

> lucene query: only QueryParser run well
> ---------------------------------------
>
>                 Key: SOLR-16514
>                 URL: https://issues.apache.org/jira/browse/SOLR-16514
>             Project: Solr
>          Issue Type: Task
>      Security Level: Public(Default Security Level. Issues are Public) 
>          Components: clients - python
>            Reporter: Nicola Paganotti
>            Priority: Critical
>              Labels: newbie
>
> {code:java}
>     def searchGiustizia(self,startPagination,recPerPage):
>         indexPath = File(self.fileLucene).toPath()
>         directory = FSDirectory.open(indexPath)
>         searcher = IndexSearcher(DirectoryReader.open(directory))                      
>         paQuery5 = TermQuery(Term("parte","TELESI RICCARDO"))
>         analyzer = StandardAnalyzer()        print 
>         ("\n------------------------------------------------------")
>         start = datetime.now()
>         collector = TotalHitCountCollector()
>         searcher.search(paQuery5, collector)
>         print("found: ",collector.getTotalHits())        
>         duration = datetime.now() - start
>         print("time ",str(duration))
>         print ("\n------------------------------------------------------") {code}
> This function do a simple search in my Index of Apache Lucene. I use TermQuery but it return no results. If I use QueryParser, Lucene find me record with parte = "TELESI RICCARDO". Why doesn't TermQuery work?



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org