Pooja,
have a look at Solr's DataImportHandler. XPathEntityProcessor [1] should
suit your needs.
Best,
Sascha
[1] http://wiki.apache.org/solr/DataImportHandler#XPathEntityProcessor
Pooja Verlani schrieb:
Hi,
I want to index an xml like following:
<officer>
<name>John</name>
<dob>1979-29-17T28:14:48Z</dob>
<collegeGroup>
<college>
<name>ABC College</name>
<year>1998</year>
</college>
<college>
<name>PQRS College</name>
<year>2001</year>
</college>
<college>
<name>XYZ College</name>
<year>2003</year>
</college>
</collegeGroup>
</officer>
I am not able to judge how should be the schema like?
Also, if I flatten such an xml and make collegename & year as multivalued
like this:
<college_name>ABC College, PQRS College, XYZ College</college_name>
<college_year>1998,2001,2003</year>
In such a scenario I can't make a coorespondence between ABC college & year
1998.
In case someone has an efficient way out, do share.
Thanks in anticipation.
Regards,
Pooja