Thanks for your comment.
What I need is to model it so that i can connect between the featureName
and the feature description of the.
Currently if item has 3 features I get two list - each three elements long.
But then I need to correlate them.



On Sun, Jun 23, 2013 at 9:25 AM, Gora Mohanty <g...@mimirtech.com> wrote:

> On 23 June 2013 01:31, Mysurf Mail <stammail...@gmail.com> wrote:
> > I try to model my db using
> > this<http://wiki.apache.org/solr/DataImportHandler#Full_Import_Example
> >example
> > from solr wiki.
> >
> > I have a table called item and a table called features with
> > id,featureName,description
> >
> > here is the updated xml (added featureName)
> >
> > <dataConfig>
> >     <dataSource driver="org.hsqldb.jdbcDriver"
> > url="jdbc:hsqldb:/temp/example/ex" user="sa" />
> >     <document>
> >         <entity name="item" query="select * from item">
> >             <entity name="feature" query="select description,
> > featureName as features from feature where item_id='${item.ID}'"/>
> >         </entity>
> >     </document>
> >
> >
> > Now I get two lists in the xml element
> >
> > <doc>
> > <arr name="featureName">
> > <str>number of miles in every direction the universal cataclysm was
> > gathering</str> <str>All around the Restaurant people and things relaxed
> > and chatted. The</str> <str>- Do we have... - he put up a hand to hold
> back
> > the cheers, - Do we</str> </arr> <arr name="description">
> > <str>to a stupefying climax. Glancing at his watch, Max returned to the
> > stage</str> <str>air was filled with talk of this and that, and with the
> > mingled scents of</str> <str>have a party here from the Zansellquasure
> > Flamarion Bridge Club from</str>
> > </arr>.
> > </doc>
> > But I would like to see the list together (using xml attributes) so that
> I
> > dont have to join the values.
> > Is it possible?
>
> While it is not clear to me what you are asking, I am
> guessing that you do not want the featureName and
> description fields to appear as arrays. This is happening
> because you have defined them as multi-valued in the
> Solr schema. What exactly do you want to "join" here?
>
> Regards,
> Gora
>

Reply via email to