Hi,

I am trying to use DIH custom function by referring 
http://wiki.apache.org/solr/DIHCustomFunctions, I have prepared jar file 
containing my custom class and placed it in solr lib directory. For Full-import 
command, I am  getting "Full Import failed:java.lang.NoClassDefFoundError: 
org/apache/solr/handler/dataimport/Evaluator" exception.

As there is no enough documentation available I am stuck, tried adding 
dependencies didn't worked. Any pointers or suggestions is appreciated.

package com.custom;
import org.apache.solr.handler.dataimport.Evaluator;
import org.apache.solr.handler.dataimport.VariableResolver;

public class PrepareQuery extends Evaluator
{
                @Override
                public String evaluate(VariableResolver arg0, String arg1) {
                                String subQueryStr = "select ID, CATEGORY_NAME 
from CATEGORY_MASTER where ID=" + arg1;
                                return subQueryStr.toString();
                }
}

<dataConfig>
<function name="getquery" class="com.custom.PrepareQuery"/>
....
...
<entity name="psvSubEntity"
                                                  
query="'${dih.functions.getquery(1)}'">



Thanks
Aviraj


DISCLAIMER
==========
This e-mail may contain privileged and confidential information which is the 
property of Persistent Systems Ltd. It is intended only for the use of the 
individual or entity to which it is addressed. If you are not the intended 
recipient, you are not authorized to read, retain, copy, print, distribute or 
use this message. If you have received this communication in error, please 
notify the sender and delete all copies of this message. Persistent Systems 
Ltd. does not accept any liability for virus infected mails.

Reply via email to