spellcheck in dismax

2011-11-22 Thread Ruixiang Zhang
I put the following into dismax requestHandler, but no suggestion field is
returned.


  true
  false
  1


  spellcheck


But everything works if I put it as a separate requestHandler. Did I miss
something?

Thanks
Richard


Re: Solr 3.2.0 is not writing log

2011-08-01 Thread Ruixiang Zhang
It works perfectly! Thank you so much!!!

Ruixiang

On Sun, Jul 31, 2011 at 7:56 PM, tmahesh  wrote:

> In etc/jetty.xml, at line 204, you should remove the comment (delete line
> 204
> and line 218)
>
>204
>
>
> --
> View this message in context:
> http://lucene.472066.n3.nabble.com/Solr-3-2-0-is-not-writing-log-tp3208945p3214774.html
> Sent from the Solr - User mailing list archive at Nabble.com.
>


Solr 3.2.0 is not writing log

2011-07-29 Thread Ruixiang Zhang
I'm using Solr 1.4 with jetty for my site, it writes log into files in
example/logs.

Now I'm testing Solr 3.2.0 with jetty on another server, but no log is
written into this folder: example/logs. It is always empty.

Do I need to do something to turn on the log? Any hint will be appreciated.


Ruixiang


Index rows with NULL value

2011-07-15 Thread Ruixiang Zhang
Hi

It seems that solr does not index a row when some column of this row has
NULL value.
How can I make solr index these rows?

Thanks
Ruixiang


Where to find the Log file

2011-06-09 Thread Ruixiang Zhang
Where can I find the log file of solr? Is it turned on by default? (I use
Jetty)

Thanks
Ruixiang


Re: How to upgrade to Solr4.0 to use Result Grouping?

2011-03-21 Thread Ruixiang Zhang
Is it the file 
apache-solr-4.0-2011-03-18_08-07-35-src.tgz<https://builds.apache.org/hudson/job/Solr-trunk/lastSuccessfulBuild/artifact/artifacts/apache-solr-4.0-2011-03-18_08-07-35-src.tgz>
on page
https://builds.apache.org/hudson/job/Solr-trunk/lastSuccessfulBuild/artifact/artifacts/?

Thanks
Richard

On Mon, Mar 21, 2011 at 12:30 PM, Ruixiang Zhang  wrote:

> Thanks. Then where is the link to download the latest 4.0?
>
> Richard
>
>
> On Mon, Mar 21, 2011 at 11:57 AM, Yonik Seeley  > wrote:
>
>> On Mon, Mar 21, 2011 at 10:20 AM, Erick Erickson
>>  wrote:
>> > Get the release and re-index? You can get a trunk
>> > version either through SVN or from the nightly build
>> > at https://builds.apache.org/hudson/view/S-Z/view/Solr/
>> >
>> > Note that 3.1 also has result grouping
>>
>> Result grouping / field collapsing is in trunk (4.0-dev) only.
>>
>> -Yonik
>> http://www.lucenerevolution.org -- Lucene/Solr User Conference, May
>> 25-26, San Francisco
>>
>
>


Re: How to upgrade to Solr4.0 to use Result Grouping?

2011-03-21 Thread Ruixiang Zhang
Thanks. Then where is the link to download the latest 4.0?

Richard

On Mon, Mar 21, 2011 at 11:57 AM, Yonik Seeley
wrote:

> On Mon, Mar 21, 2011 at 10:20 AM, Erick Erickson
>  wrote:
> > Get the release and re-index? You can get a trunk
> > version either through SVN or from the nightly build
> > at https://builds.apache.org/hudson/view/S-Z/view/Solr/
> >
> > Note that 3.1 also has result grouping
>
> Result grouping / field collapsing is in trunk (4.0-dev) only.
>
> -Yonik
> http://www.lucenerevolution.org -- Lucene/Solr User Conference, May
> 25-26, San Francisco
>


Re: How to upgrade to Solr4.0 to use Result Grouping?

2011-03-21 Thread Ruixiang Zhang
Hi Erick

Thanks for your reply. 3.1 should be OK for me. When will it be release and
where is the link to download it? Thanks

Richard


On Mon, Mar 21, 2011 at 7:20 AM, Erick Erickson wrote:

> Get the release and re-index? You can get a trunk
> version either through SVN or from the nightly build
> at https://builds.apache.org/hudson/view/S-Z/view/Solr/
>
> Note that 3.1 also has result grouping, and is currently
> being released, so you might want to consider that
> version.
>
> Best
> Erick
>
> On Sun, Mar 20, 2011 at 9:28 PM, Ruixiang Zhang  wrote:
> > I want to use the Result Grouping feature that's only available for
> Solr4.0.
> > Currently, I have Solr1.4.1 installed.
> > I want to know how to upgrade it to Solr4.0 so that I can use Result
> > Grouping?
> >
> > Thanks a lot!!!
> > Richard
> >
>


How to upgrade to Solr4.0 to use Result Grouping?

2011-03-20 Thread Ruixiang Zhang
I want to use the Result Grouping feature that's only available for Solr4.0.
Currently, I have Solr1.4.1 installed.
I want to know how to upgrade it to Solr4.0 so that I can use Result
Grouping?

Thanks a lot!!!
Richard


Problem of results ordering

2010-12-23 Thread Ruixiang Zhang
When I search "guitar center 94305", it gives the results:

guitar center guitar center Hollywood
guitar center 94305
guitar center 94305 location

But I want results to be like this:

guitar center 94305
guitar center 94305 location
guitar center guitar center Hollywood

How can I make the results that match all keywords come first?
Or how can I reduce the weight of the word that appears the second or more
time?

Thanks
Ruixiang


Re: Print highlighting descriptions

2010-12-22 Thread Ruixiang Zhang
Hi Koji

I figured it out. I can use
response.highlighting[response.response.docs[0].id].description[0]
to print the description in highlighting.

(Actually, it's not a solr question, sorry for that.)

Thanks
Ruixiang

On Wed, Dec 22, 2010 at 10:05 PM, Koji Sekiguchi  wrote:

> (10/12/23 14:10), Ruixiang Zhang wrote:
>
>> Thanks Koji. Actually my question is:
>>
>> We can use  response.response.docs[i].description
>> to print the description in docs.
>>
>> What expression should we use to print the description in highlighting?
>>
>
> Ruixiang,
>
> I cannot understand your question. Is it Solr question? :)
> You said "No need to highlight, just print out" in your previous mail,
> then asked above???
>
> What do you mean by "expression" and "print"?
>
>
> Koji
> --
> http://www.rondhuit.com/en/
>


Re: Print highlighting descriptions

2010-12-22 Thread Ruixiang Zhang
Thanks Koji. Actually my question is:

We can use  response.response.docs[i].description
to print the description in docs.

What expression should we use to print the description in highlighting?


Print highlighting descriptions

2010-12-22 Thread Ruixiang Zhang
I want to print the highlighting descriptions:

{"responseHeader":{"status":0,
"QTime":2,"params":{"hl.fl":"description","json.wrf":"jsonp1293069622009","wt":"json","q":"target","hl":"true"}},"response":{"numFound":7945,"start":0,"maxScore":6.9186745,"docs":[{"description":"target","url":"target","id":"269653","score":6.9186745},{"description":"Target
The
Woodlands","url":"Target_The_Woodlands","id":"37277","score":4.3241715},{"description":"Target
Kent","url":"Target_Kent","id":"37275","score":4.3241715}]},
"highlighting":{"269653":{"description":["target
"]},"37277":{"description":["Target The
Woodlands"]},"37275":{"description":["Target
Kent"]}}}

I know the descriptions in docs is:  response.response.docs[i].description
But I don't know how to print out the highlighting descriptions, such as
"Target Kent" (No need to highlight, just print out).

Thanks
Ruixiang


Re: Crontab for delta-import

2010-12-22 Thread Ruixiang Zhang
Thanks for your quick reply. I couldn't find the wget on my server. Do you
know where it should be located or how I can check if I have it on my
server? If not, can I install one?

Thanks

On Wed, Dec 22, 2010 at 3:38 AM, Stefan Moises  wrote:

> Hi,
>
> you can use wget if available on your server, e.g. command
> wget --quiet '
> http://181.163.64.228:8983/solr/db/dataimport?command=delta-import'
>
> Cheers,
> Stefan
>
> Am 22.12.2010 12:31, schrieb Ruixiang Zhang:
>
>  I want to run delta-import in Crontab but don't know how.
>>
>> I used php file in Crontab before, like:
>>
>> command: php /home/user/public_html/auto.php
>>
>> I tried:
>>
>> command:
>>
>> /home/user/public_html/solr/apache-solr-1.4.1/example/example-DIH/solr/db/dataimport?command=delta-import
>>
>> It didn't work.
>>
>> The url I run in browser is:
>>
>> http://181.163.64.228:8983/solr/db/dataimport?command=delta-import
>>
>> Thanks
>> Richard
>>
>>
> --
> ***
> Stefan Moises
> Senior Softwareentwickler
>
> shoptimax GmbH
> Guntherstraße 45 a
> 90461 Nürnberg
> Amtsgericht Nürnberg HRB 21703
> GF Friedrich Schreieck
>
> Tel.: 0911/25566-25
> Fax:  0911/25566-29
> moi...@shoptimax.de
> http://www.shoptimax.de
> ***
>
>
>


Crontab for delta-import

2010-12-22 Thread Ruixiang Zhang
I want to run delta-import in Crontab but don't know how.

I used php file in Crontab before, like:

command: php /home/user/public_html/auto.php

I tried:

command:
/home/user/public_html/solr/apache-solr-1.4.1/example/example-DIH/solr/db/dataimport?command=delta-import

It didn't work.

The url I run in browser is:

http://181.163.64.228:8983/solr/db/dataimport?command=delta-import

Thanks
Richard


Re: Dataimport: Could not load driver: com.mysql.jdbc.Driver

2010-12-05 Thread Ruixiang Zhang
Hi Koji

I finally found the reason for this problem:

I download the tar file of the driver and unzip it in windows. Then I put
the jar file into the server. I don' t know why, but it doesn't work. It
works when I put the tar file and unzip it in the server.

Thanks a lot for your time!!!
Richard



On Sun, Dec 5, 2010 at 3:02 AM, Ruixiang Zhang  wrote:

> And here are the logs:
>
>
> Dec 5, 2010 2:00:23 AM org.apache.solr.handler.dataimport.DataImportHandler
> processConfiguration
> INFO: Processing configuration from solrconfig.xml:
> {config=db-data-config.xml}
> Dec 5, 2010 2:00:23 AM org.apache.solr.handler.dataimport.DataImporter
> loadDataConfig
> INFO: Data Configuration loaded successfully
> Dec 5, 2010 2:00:23 AM org.apache.solr.handler.dataimport.DataImporter
> verifyWithSchema
> INFO: The field :title present in DataConfig does not have a counterpart in
> Solr Schema
> Dec 5, 2010 2:00:23 AM org.apache.solr.handler.dataimport.DataImporter
> verifyWithSchema
> INFO: The field :url present in DataConfig does not have a counterpart in
> Solr Schema
> Dec 5, 2010 2:00:23 AM org.apache.solr.handler.dataimport.DataImporter
> doFullImport
> INFO: Starting Full Import
> Dec 5, 2010 2:00:23 AM org.apache.solr.handler.dataimport.SolrWriter
> readIndexerProperties
> INFO: Read dataimport.properties
> Dec 5, 2010 2:00:23 AM org.apache.solr.handler.dataimport.DataImporter
> doFullImport
> SEVERE: Full Import failed
> *org.apache.solr.handler.dataimport.DataImportHandlerException: Could not
> load driver: com.mysql.jdbc.Driver* Processing Document # 1
> at
> org.apache.solr.handler.dataimport.DataImportHandlerException.wrapAndThrow(DataImportHandlerException.java:72)
> at
> org.apache.solr.handler.dataimport.JdbcDataSource.createConnectionFactory(JdbcDataSource.java:114)
> at
> org.apache.solr.handler.dataimport.JdbcDataSource.init(JdbcDataSource.java:62)
> at
> org.apache.solr.handler.dataimport.DataImporter.getDataSourceInstance(DataImporter.java:304)
> at
> org.apache.solr.handler.dataimport.ContextImpl.getDataSource(ContextImpl.java:94)
> at
> org.apache.solr.handler.dataimport.SqlEntityProcessor.init(SqlEntityProcessor.java:52)
> at
> org.apache.solr.handler.dataimport.EntityProcessorWrapper.init(EntityProcessorWrapper.java:71)
> at
> org.apache.solr.handler.dataimport.DocBuilder.buildDocument(DocBuilder.java:319)
> at
> org.apache.solr.handler.dataimport.DocBuilder.doFullDump(DocBuilder.java:242)
> at
> org.apache.solr.handler.dataimport.DocBuilder.execute(DocBuilder.java:180)
> at
> org.apache.solr.handler.dataimport.DataImporter.doFullImport(DataImporter.java:331)
> at
> org.apache.solr.handler.dataimport.DataImporter.runCmd(DataImporter.java:389)
> at
> org.apache.solr.handler.dataimport.DataImportHandler.handleRequestBody(DataImportHandler.java:203)
> at
> org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHandlerBase.java:131)
> at org.apache.solr.core.SolrCore.execute(SolrCore.java:1316)
> at
> org.apache.solr.servlet.SolrDispatchFilter.execute(SolrDispatchFilter.java:338)
> at
> org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:241)
> at
> org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1089)
> at
> org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:365)
> at
> org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216)
> at
> org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:181)
> at
> org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:712)
> at
> org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:405)
> at
> org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:211)
> at
> org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114)
> at
> org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:139)
> at org.mortbay.jetty.Server.handle(Server.java:285)
> at
> org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:502)
> at
> org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:821)
> at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:513)
> at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:208)
> at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:378)
> at
> org.mortbay.jetty.bio.SocketConnector$Connection.run(Soc

Re: Dataimport: Could not load driver: com.mysql.jdbc.Driver

2010-12-05 Thread Ruixiang Zhang
ssLoader$1.run(URLClassLoader.java:200)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at java.net.FactoryURLClassLoader.loadClass(URLClassLoader.java:579)
at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:242)
at
org.apache.solr.core.SolrResourceLoader.findClass(SolrResourceLoader.java:359)
... 34 more
Dec 5, 2010 2:00:23 AM org.apache.solr.update.DirectUpdateHandler2 rollback
INFO: start rollback
Dec 5, 2010 2:00:23 AM org.apache.solr.update.DirectUpdateHandler2 rollback
INFO: end_rollback


Thanks
Richard



On Sun, Dec 5, 2010 at 2:56 AM, Ruixiang Zhang  wrote:

> Thanks Koji.
>
> I just tried to change the permission of the driver file to 777, still can
> not found the driver.
>
> I put the driver into the folder with the original driver is and deleted
> the original one. I don't know why solr can find the original one (if I
> don't change anything), but not this one.
>
> Thanks
> Richard
>
>
> On Sun, Dec 5, 2010 at 2:46 AM, Koji Sekiguchi  wrote:
>
>> (10/12/05 18:38), Ruixiang Zhang wrote:
>>
>>> *I got the following error for dataimport:*
>>>
>>>
>>> *Full Import failed
>>> org.apache.solr.handler.dataimport.DataImportHandlerException: Could not
>>> load driver: com.mysql.jdbc.Driver*
>>>
>>> I have the following files:
>>>
>>> \example-DIH\solr\db\conf\   solrconfig.xml, schema.xml,
>>> db-data-config.xml,
>>> dataimport.properties
>>> \example-DIH\solr\db\lib\   mysql-connector-java-5.1.13-bin.jar
>>>
>>
>> I guess the problem is the permission of the driver file?
>>
>> Koji
>> --
>> http://www.rondhuit.com/en/
>>
>
>


Re: Dataimport: Could not load driver: com.mysql.jdbc.Driver

2010-12-05 Thread Ruixiang Zhang
Thanks Koji.

I just tried to change the permission of the driver file to 777, still can
not found the driver.

I put the driver into the folder with the original driver is and deleted the
original one. I don't know why solr can find the original one (if I don't
change anything), but not this one.

Thanks
Richard


On Sun, Dec 5, 2010 at 2:46 AM, Koji Sekiguchi  wrote:

> (10/12/05 18:38), Ruixiang Zhang wrote:
>
>> *I got the following error for dataimport:*
>>
>>
>> *Full Import failed
>> org.apache.solr.handler.dataimport.DataImportHandlerException: Could not
>> load driver: com.mysql.jdbc.Driver*
>>
>> I have the following files:
>>
>> \example-DIH\solr\db\conf\   solrconfig.xml, schema.xml,
>> db-data-config.xml,
>> dataimport.properties
>> \example-DIH\solr\db\lib\   mysql-connector-java-5.1.13-bin.jar
>>
>
> I guess the problem is the permission of the driver file?
>
> Koji
> --
> http://www.rondhuit.com/en/
>


Dataimport: Could not load driver: com.mysql.jdbc.Driver

2010-12-05 Thread Ruixiang Zhang
*I got the following error for dataimport:*

*Full Import failed
org.apache.solr.handler.dataimport.DataImportHandlerException: Could not
load driver: com.mysql.jdbc.Driver*

I have the following files:

\example-DIH\solr\db\conf\   solrconfig.xml, schema.xml, db-data-config.xml,
dataimport.properties
\example-DIH\solr\db\lib\   mysql-connector-java-5.1.13-bin.jar



*I put this code to solrconfig.xml:*

   

db-data-config.xml

  

*And these in db-data-config.xml:*




  
  





  




Solr server has been restarted after these change.


Any hint or suggestions will be appreciated!!!

Thanks
Richard


Re: solr/admin/dataimport Not Found

2010-12-02 Thread Ruixiang Zhang
Thank you so much, Koji, the example-DIH works. I'm reading for details...

Richard


On Thu, Dec 2, 2010 at 4:39 PM, Koji Sekiguchi  wrote:

> (10/12/03 9:29), Ruixiang Zhang wrote:
>
>> Hi Koji
>>
>> Thanks for your reply.
>> I pasted the wrong link.
>> Actually I tried this fist http://mydomain.com:8983/solr/dataimport
>> It didn't work.
>> The page should be there after installation, right? Did I miss something?
>>
>> Thanks a lot!
>> Richard
>>
>
> To work that URL, you have to have a request handler in your
> solrconfig.xml:
>
>class="org.apache.solr.handler.dataimport.DataImportHandler">
>
>db-data-config.xml
>
>  
>
> If you try DIH for the first time, please read
> solr/example/example-DIH/README.txt
> and try example-DIH first.
>
>
> Koji
> --
> http://www.rondhuit.com/en/
>


Re: solr/admin/dataimport Not Found

2010-12-02 Thread Ruixiang Zhang
Hi Koji

Thanks for your reply.
I pasted the wrong link.
Actually I tried this fist http://mydomain.com:8983/solr/dataimport
It didn't work.
The page should be there after installation, right? Did I miss something?

Thanks a lot!
Richard





On Thu, Dec 2, 2010 at 4:23 PM, Koji Sekiguchi  wrote:

> (10/12/03 8:58), Ruixiang Zhang wrote:
>
>> I tried to import data from mysql. When I tried to run
>> http://mydomain.com:8983/solr/admin/dataimport , I got these error
>> message:
>>
>> HTTP ERROR: 404
>>
>> NOT_FOUND
>>
>> RequestURI=/solr/admin/dataimport
>>
>> *Powered by Jetty://<http://jetty.mortbay.org/>
>>
>>
>>
>> *
>> Any help will be appreciated!!!
>> Thanks
>> Richard
>>
>
> Richard,
>
> Usually, it should be http://mydomain.com:8983/solr/dataimport
>
> Koji
> --
> http://www.rondhuit.com/en/
>


solr/admin/dataimport Not Found

2010-12-02 Thread Ruixiang Zhang
I tried to import data from mysql. When I tried to run
http://mydomain.com:8983/solr/admin/dataimport , I got these error message:

HTTP ERROR: 404

NOT_FOUND

RequestURI=/solr/admin/dataimport

*Powered by Jetty:// 


*
Any help will be appreciated!!!
Thanks
Richard


Cannot start Solr anymore

2010-12-02 Thread Ruixiang Zhang
Hi, I'm new here.

First, could anyone tell me how to restart solr?

I started solr and killed the process. Then when I tried to start it again,
it failed:

$ java -jar start.jar
2010-12-02 14:28:00.011::INFO:  Logging to STDERR via
org.mortbay.log.StdErrLog
2010-12-02 14:28:00.099::INFO:  jetty-6.1.3
2010-12-02 14:28:00.231::WARN:  Failed startup of context
org.mortbay.jetty.webapp.webappcont...@73901437
{/solr,jar:file:/.../solr/apache-solr-1.4.1/example/webapps/solr.war!/}
java.util.zip.ZipException: invalid END header (bad central directory
offset)


Thanks
Richard