You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by Thiago Jackiw <tj...@gmail.com> on 2007/08/09 23:35:57 UTC

Returning a list of matching words

This may be obvious but I can't get my head straight. Is there a way
to return a list of matching words that a record got matched against?
For instance:

record_a: ruby, solr, mysql, rails
record_b: solr, java

Then ?q=solr+OR+rails would return the matched words for the records

record_a: solr, rails
record_b: solr

I'm not looking into using the highlight feature for that.

Thanks,

--
Thiago Jackiw

Re: tomcat and solr multiple instances

Posted by Pieter Berkel <pi...@gmail.com>.
The current working directory (Cwd) is the directory from which you started
the Tomcat server and is not dependent on the Solr instance configurations.
So as long as SolrHome is correct for each Solr instance, you shouldn't have
a problem.

cheers,
Piete



On 10/08/07, Jae Joo <jj...@ecnext.com> wrote:
>
> Here are the Catalina/localhost/ files
> For "example" instance
> <Context docBase="/rpt/src/apache-solr-1.2.0/dist/solr.war"
>          debug="0" crossContext="true">
> <Environment name="solr/home" type="java.lang.String"
> value="/rpt/src/apache-solr-1.2.0/example/solr"
> override="true" />
>
> </Context>
>
>
> For ca_companies instance
>
> <Context docBase="/rpt/src/apache-solr-1.2.0/dist/solr.war"
>          debug="0" crossContext="true">
> <Environment name="solr/home" type="java.lang.String"
> value="/rpt/src/apache-solr-1.2.0/ca_companies/solr"
> override="true" />
>
> </Context>
>
>
> Urls
> http://host:8080/solr/admin --> pointint "example" instance (Problem...)
> http://host:8080/solr_ca/admin --> pointing "ca-companies" instance (it
> is working)
>
> -----Original Message-----
> From: Jae Joo [mailto:jjoo@ECNext.com]
> Sent: Thursday, August 09, 2007 5:45 PM
> To: solr-user@lucene.apache.org
> Subject: tomcat and solr multiple instances
>
> Hi,
>
>
>
> I have built 2 solr instance - one is "example" and the other is
> "ca_companies".
>
>
>
> The "ca_companies" solr instance is working find, but "example is not
> working...
>
>
>
> In the admin page, "/solr/admin", for "example" instance, it shows that
>
>
>
> Cwd=/rpt/src/apache-solr-1.2.0/ca_companies/solr/conf
>
> --> this should be
>
> Cwd=/rpt/src/apache-solr-1.2.0/example/solr/conf
>
>
>
> SolrHome=/rpt/src/apache-solr-1.2.0/example/solr/
>
>
>
> Any one knows why?
>
>
>
> If I run Jetty for instance "example", it is working well...
>
>
>
> Thanks,
>
>
>
> Jae Joo
>
>

RE: tomcat and solr multiple instances

Posted by Jae Joo <jj...@ECNext.com>.
Here are the Catalina/localhost/ files
For "example" instance
<Context docBase="/rpt/src/apache-solr-1.2.0/dist/solr.war"
         debug="0" crossContext="true">
<Environment name="solr/home" type="java.lang.String"
value="/rpt/src/apache-solr-1.2.0/example/solr"
override="true" />

</Context>


For ca_companies instance

<Context docBase="/rpt/src/apache-solr-1.2.0/dist/solr.war"
         debug="0" crossContext="true">
<Environment name="solr/home" type="java.lang.String"
value="/rpt/src/apache-solr-1.2.0/ca_companies/solr"
override="true" />

</Context>


Urls
http://host:8080/solr/admin --> pointint "example" instance (Problem...)
http://host:8080/solr_ca/admin --> pointing "ca-companies" instance (it
is working)

-----Original Message-----
From: Jae Joo [mailto:jjoo@ECNext.com] 
Sent: Thursday, August 09, 2007 5:45 PM
To: solr-user@lucene.apache.org
Subject: tomcat and solr multiple instances

Hi,

 

I have built 2 solr instance - one is "example" and the other is
"ca_companies".

 

The "ca_companies" solr instance is working find, but "example is not
working...

 

In the admin page, "/solr/admin", for "example" instance, it shows that

 

Cwd=/rpt/src/apache-solr-1.2.0/ca_companies/solr/conf  

--> this should be 

Cwd=/rpt/src/apache-solr-1.2.0/example/solr/conf  

 

SolrHome=/rpt/src/apache-solr-1.2.0/example/solr/

 

Any one knows why?

 

If I run Jetty for instance "example", it is working well...

 

Thanks,

 

Jae Joo


Re: tomcat and solr multiple instances

Posted by Chris Hostetter <ho...@fucit.org>.
: Message-ID:
:     <D2...@sbs03.ecnext03.local>
: In-Reply-To: <20...@mail.gmail.com>

http://people.apache.org/~hossman/#threadhijack

When starting a new discussion on a mailing list, please do not reply to
an existing message, instead start a fresh email.  Even if you change the
subject line of your email, other mail headers still track which thread
you replied to and your question is "hidden" in that thread and gets less
attention.   It makes following discussions in the mailing list archives
particularly difficult.
See Also:  http://en.wikipedia.org/wiki/Thread_hijacking




-Hoss


tomcat and solr multiple instances

Posted by Jae Joo <jj...@ECNext.com>.
Hi,

 

I have built 2 solr instance - one is "example" and the other is
"ca_companies".

 

The "ca_companies" solr instance is working find, but "example is not
working...

 

In the admin page, "/solr/admin", for "example" instance, it shows that

 

Cwd=/rpt/src/apache-solr-1.2.0/ca_companies/solr/conf  

--> this should be 

Cwd=/rpt/src/apache-solr-1.2.0/example/solr/conf  

 

SolrHome=/rpt/src/apache-solr-1.2.0/example/solr/

 

Any one knows why?

 

If I run Jetty for instance "example", it is working well...

 

Thanks,

 

Jae Joo


Re: Returning a list of matching words

Posted by Yonik Seeley <yo...@apache.org>.
On 8/9/07, Thiago Jackiw <tj...@gmail.com> wrote:
> This may be obvious but I can't get my head straight. Is there a way
> to return a list of matching words that a record got matched against?

Unfortunately no... lucene doesn't provide that capability with
standard queries.
You could do it (slower) with additional queries of course:

q=solr OR rails&rows=5  // retrieves the top docs
q=solr OR rails&fq=solr&fl=id  // see which top docs match solr
q=solr OR rails&fq=rails&f=id  // see which top docs match rails

-Yonik