Hmm, okay, I guess I wasn't taking the hierarchy-flattening aspect of Solr seriously enough. :)
Based on your reply from the other thread, I guess the best solution, as far as I can tell, is to maintain the multiple value lists and take advantage of the fact that the arrays will always be in the right order: <arr name="manu_id"> <int>1</int> <int>2</int> </arr> <arr name="manu_name"> <str>ABC Corp</str> <!-- ID should be 1, right? --> <str>XYZ Inc</str> <!-- Should be 2 --> </arr> So I guess the problem isn't really *sooo* bad...I just need to make sure that I have the appropriate names defined so I can link between two arrays in my client code. I suppose I could keep things straight by preserving the hierarchy within the name attribute. -----Original Message----- From: harrysmith [mailto:harrysmith...@gmail.com] Sent: Friday, October 22, 2010 4:10 PM To: solr-user@lucene.apache.org Subject: Re: Confusion about entities and documents >What I get when I search for, say, "XYZ", is a document that has XYZ Corp as a manufacturer name, but the >array of parts_manu appears to be a child of the document, not the parts array. > >Is this the correct behavior, insofar as a document has a single level of elements, and that's it? If so, what >might be a better strategy for being able to maintain the hierarchy of information within a document? > Yes, this is the correct behavior. I still struggle with the same issue, and there is no 'best practices' (that I have found at least) of maintaining relationships within a Solr doc. The argument is Solr is not the correct place for these representations and should only represent a flat version of your document. For a similar question see: http://lucene.472066.n3.nabble.com/Schema-Definition-Question-td1049966.html#a1105593 A few possible solutions are posted there, and i'm interested in how others have tackled this issue. -- View this message in context: http://lucene.472066.n3.nabble.com/Confusion-about-entities-and-documents-tp1753926p1755152.html Sent from the Solr - User mailing list archive at Nabble.com. DISCLAIMER: This electronic message, including any attachments, files or documents, is intended only for the addressee and may contain CONFIDENTIAL, PROPRIETARY or LEGALLY PRIVILEGED information. If you are not the intended recipient, you are hereby notified that any use, disclosure, copying or distribution of this message or any of the information included in or with it is unauthorized and strictly prohibited. If you have received this message in error, please notify the sender immediately by reply e-mail and permanently delete and destroy this message and its attachments, along with any copies thereof. This message does not create any contractual obligation on behalf of the sender or Law Bulletin Publishing Company. Thank you.