Problem retrieving results

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Problem retrieving results

Alex Gadea
I am suddenly experiencing a problem retrieving results from a SOLR installation.  The install shows that there are documents indexed and I have issued multiple commits.  When I execute a query I receive 0 results back, but when I close the query handler, it indicates that the queryResultCache had a hit ratio of 66%.  I have deleted the index directory and recreated it.  I'm relatively new to SOLR and have no idea what to look at next.  Any suggestions?  Is there any way to issue a query against SOLR that will return all records in the index?

Thanks.
Alex
Reply | Threaded
Open this post in threaded view
|

Re: Problem retrieving results

Yonik Seeley-2
On Mon, Sep 8, 2008 at 12:16 PM, Alex Gadea <[hidden email]> wrote:
> Is there any way to issue a query against SOLR that will return all records in the index?

http://localhost:8983/solr/select?q=*:*

Checking the admin stats page should also tell you the number of
documents in the index.

-Yonik
Reply | Threaded
Open this post in threaded view
|

Re: Problem retrieving results

Alex Gadea
In reply to this post by Alex Gadea
On the stats page it shows:

caching : true
numDocs : 170
maxDoc : 340
readerImpl : MultiReader
readerDir : org.apache.lucene.store.FSDirectory@/usr/local/apache-solr/example/solr/data/index
indexVersion : 1220876093260
openedAt : Mon Sep 08 13:58:17 EDT 2008
registeredAt : Mon Sep 08 13:58:18 EDT 2008

If I use the query to retrieve all, I get all the results so at least I know they are there.  Phew!  If I do a query of:

http://localhost:8983/solr/select?q=suit

I get nothing even though one of the records that was returned includes that word in it.

Thanks,

Alex


----- Original Message -----
From: "Yonik Seeley" <[hidden email]>
To: [hidden email]
Sent: Monday, September 8, 2008 12:28:41 PM GMT -05:00 US/Canada Eastern
Subject: Re: Problem retrieving results

On Mon, Sep 8, 2008 at 12:16 PM, Alex Gadea <[hidden email]> wrote:
> Is there any way to issue a query against SOLR that will return all records in the index?

http://localhost:8983/solr/select?q=*:*

Checking the admin stats page should also tell you the number of
documents in the index.

-Yonik
Reply | Threaded
Open this post in threaded view
|

Re: Problem retrieving results

Alex Gadea
Never mind.  I figured out the problem - there was a copyField that was the default field that was not setup properly.  

Thanks for the help!
Alex

----- Original Message -----
From: "Alex Gadea" <[hidden email]>
To: [hidden email]
Sent: Monday, September 8, 2008 2:01:21 PM GMT -05:00 US/Canada Eastern
Subject: Re: Problem retrieving results

On the stats page it shows:

caching : true
numDocs : 170
maxDoc : 340
readerImpl : MultiReader
readerDir : org.apache.lucene.store.FSDirectory@/usr/local/apache-solr/example/solr/data/index
indexVersion : 1220876093260
openedAt : Mon Sep 08 13:58:17 EDT 2008
registeredAt : Mon Sep 08 13:58:18 EDT 2008

If I use the query to retrieve all, I get all the results so at least I know they are there.  Phew!  If I do a query of:

http://localhost:8983/solr/select?q=suit

I get nothing even though one of the records that was returned includes that word in it.

Thanks,

Alex


----- Original Message -----
From: "Yonik Seeley" <[hidden email]>
To: [hidden email]
Sent: Monday, September 8, 2008 12:28:41 PM GMT -05:00 US/Canada Eastern
Subject: Re: Problem retrieving results

On Mon, Sep 8, 2008 at 12:16 PM, Alex Gadea <[hidden email]> wrote:
> Is there any way to issue a query against SOLR that will return all records in the index?

http://localhost:8983/solr/select?q=*:*

Checking the admin stats page should also tell you the number of
documents in the index.

-Yonik
Reply | Threaded
Open this post in threaded view
|

Re: Problem retrieving results

Yonik Seeley-2
In reply to this post by Alex Gadea
On Mon, Sep 8, 2008 at 2:01 PM, Alex Gadea <[hidden email]> wrote:
> http://localhost:8983/solr/select?q=suit
>
> I get nothing even though one of the records that was returned includes that word in it.

The field that contains "suit" may not be the default search field for
the Lucene/Solr QueryParser (see schema.xml).
You can:
 - change the default field
 - explicitly specify the field you are searching...   q=myfield:suit
 - use a multi-field query parser like DisMax and specify multiple
fields to search across

-Yonik