Is there a method to get ApacheSolr Views to work with http://drupal.org/project/apachesolr_attachments ?
i.e. For nodes with files attached, and Apachesolr Attachments (and Tika) installed, can ApacheSolr Views based searches generate hits based on attached file content?
Thanks as always! :-)
Comments
Comment #1
jax commentedHaving the same issue. The normal apachesolr search seems to function but the exposed apachsolr search filter doesn't.
Comment #2
jax commentedIn
apachesolr_views_query.incfrom theapachesolr_viewsmodule there iswhich adds
fq=entity:nodeto the search query. If you comment that out it will work but I'm not sure if that's the best approach. Needs some more investigating.Comment #3
jax commentedEven better; in
rebuild_fq()comment out the lineThat line limits the query to node entities. The file contents is stored in a "file" entity. I'm not sure why it adds that restriction by default.
Some references to make it easier to pick this up again.
http://wiki.apache.org/solr/CommonQueryParameters#fq
http://wiki.apache.org/solr/SolrQuerySyntax
Comment #4
kleinmp commentedI would like attachments to work on views as well. I'm changing this to feature request.
Comment #5
davidcalhoun commented+1 for the feature request. I ran into this same problem and was originally trying to solve it a different way. I'd like to see attachments work on Views too. In the mean time, I commented out the line stated in comment #3 and it seems to be working for me. The only issue I'm facing is getting duplicate results sometimes. It appears one for the file and one for the node the file is attached to.
Comment #6
medieval111 commentedThanks! Works for me. Looks like it's because "Apache SOLR Node" is selected as a View type...
I changed:
to:
Alternative:
Comment #7
kenorb commentedVersion 6.x is no longer supported due to Drupal 6 End of Life. For Drupal 8.x, use Search API Solr Searchinstead.