开发者

Lucene and Solr

I am creating the Index using Lucene. But using t开发者_Go百科he SolrSearch engine to search.

My problem is

  1. while I index I add each filed in my code using the code doc.add(fieldname, val, tokenized)

    1. **But my code does not see the schema file
    2. Even copy fields I need to add manually**
    3. Now I want to use the autosuggest feature of Solr
    4. I do not know how to enable this feature while creating the Index
  2. But when I use the simplePostTool to post the data through Solr all is fine.

  3. I cannot do that because I have to get some text from different urls.

    So can someone please advise me how can I achieve this? A sample code will be very helpful. In any case If I can have some code that can see the schema file and use the fieldTypes it would be great.

Thanks everyone.

--pramila


See EmbeddedSolrServer at:

http://wiki.apache.org/solr/Solrj

It's a pure Java API to Solr, which will allow you to index your documents using the schema.xml you have defined.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜