Oops. The fields were out of sync with those in schema.xml . Looking at the dynamic field name configuration in schema.xml - my dataconfig.xml file looks as follows.
<dataConfig> <dataSource driver="com.mysql.jdbc.Driver" url="jdbc:mysql://myserver/mydb" user="username" password="password" /> <document name="user"> <entity name="item" query="select id, firstname, lastname from user"> <field column="id" name="id" /> <field column="firstname" name="firstname_s" /> <field column="lastname" name="lastname_s" /> </entity> </document> </dataConfig> The naming of fields with suffix ( _s ) , as per the dynamic field naming conventions fixed the issue. On Mon, Dec 29, 2008 at 1:36 PM, Rakesh Sinha <rakesh.use...@gmail.com> wrote: > Hi - > I am testing around with the full - import functionality of Data > Import Handler. My dataconfig file looks as follows. > > > <dataConfig> > <dataSource driver="com.mysql.jdbc.Driver" url="jdbc:mysql://myserver/mydb" > user="username" password="password" /> > <document name="user"> > <entity name="item" > query="select id, firstname, lastname from user"> > <field column="id" /> > <field column="firstname" /> > <field column="lastname" /> > </entity> > </document> > </dataConfig> > > In solrconfig.xml - I am setting the access for DIH as follows. > > <requestHandler name="/dataimport" > class="org.apache.solr.handler.dataimport.DataImportHandler"> > <lst name="defaults"> > <str name="config">data-config.xml</str> > </lst> > </requestHandler> > > > When I try to access the deployed web-app ( even before hitting > full-import functionality using command ) - I am getting the following > sequence of errors. > > The field :lastname present in DataConfig does not have a counterpart > in Solr Schema > The field :firstname present in DataConfig does not have a counterpart > in Solr Schema > > The config file is very similar to what is given in the DIH wiki. > > Curious, what gives ? >