1

I have a field within a field collection that I need indexed. It's not showing up in the /admin/config/search/search_api/index/solr_node_index/fields page. I tried using this to try to add it myself, but I don't really know how to reference it. I know that the field collection is just an array of id numbers that you can reference, but I need to reference the actual field. Any help is appreciated.

1 Answer 1

0

There is an apachesolr field collection module available, which makes me think that field collection support is probably not out of the box with the apachesolr stuff.

As a matter of fact, if you look at the issue queue for the apachesolr module you can find this ticket #1810228 : Process Field Collection Items. It confirms that field collections are not supported out of the box, and the comments point to the apachesolr field collection module, and indicate that the module may be buggy...

I'd say try it, but test your integration thouroughly. And do try both available versions (alpha and dev), and see how it goes.

13
  • I'm actually using search api, not apache solr, which is supposed to have field collections built in. I found this drupal.org/node/2429355 which is a little similar, but not quite. It seems like the fields within the field collection that are shared are not being picked up.
    – Heather
    Commented Apr 10, 2015 at 17:31
  • Did you tick the "Aggregated fields" checkbox as mentioned in drupal.org/node/2429355#comment-9677915 ? I've just tried your scenario and followed the instructions in that thread and I can see my field collection under the fields list. So double check your "Aggregated fields" checkbox in the "Filters" tab.
    – rtome
    Commented Apr 11, 2015 at 23:17
  • Yes, that checkbox has been checked the whole time. It seems to me that because the field is shared between that field collection and other content types, that it's hiding the one that is in the field collection and not the one that is used by content types.
    – Heather
    Commented Apr 13, 2015 at 13:26
  • If what you mean is that you have one of your fields of the field collection used again in a content type, I jsut tried that and it works fine for me. Both show in my default index node fields admin page
    – rtome
    Commented Apr 13, 2015 at 13:36
  • Have you got your field collection listed under the "ADD RELATED FIELDS" dropdown at the bottom of the admin fields page ?
    – rtome
    Commented Apr 13, 2015 at 13:39

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.