<div dir="ltr"><div><div><div><div><div><div><div><div><div>Many times I have observed when there is a query regarding drupal and apachesolr, the drupal mailing list is almost silent. If it is only drupal fine, we can do R&amp;D, lot of books, mailing list support, we can get some insight. If it is only solr, still we can get help from books, mailing lists etc and can proceed.<br>
<br></div>When it comes to drupal and apachesolr I do not see any good book, not much help from mailing list.., its almost simple issues takes very long time to resolve.<br><br></div>Various search options, I could not get it done through apachesolr module, end up writing custom code to do complex searches (like get the documents having mandatory keyword1, keyword2, keyword3 AND optional keywords keyword4, keyword5, keyword6 and NOT HAVING keyword keyword7, keyword8 and much more....)<br>
<br></div>Still now I was doing indexing part using apache solr, Now I have a requirement, how do we reset the value of a multi-value field in index. I am sure, this can be done with few lines of code, but we do not have relevant document, or less users work on it  or whatever reason it is definitely a pain point....<br>
<br></div>I request, somebody good at apachesolr module probably write a good book and put in packt publish or amazon.., atleast we will have some reference book where can get sample example codes.. , <br><br></div>Best Regards<br>
</div>Kamal<br></div>Net Cloud Systems<br></div>Bangalore<br></div><div><div><div><div><div><div><div><br></div></div></div></div></div></div></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Mon, Jun 24, 2013 at 7:18 PM, Kamal Palei <span dir="ltr">&lt;<a href="mailto:palei.kamal@gmail.com" target="_blank">palei.kamal@gmail.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div><div><div><div><div><div><div><div>Dear All<br></div>I have added a multi value field in schema file (say skillset). In my     <b>_apachesolr_index_document_build</b> hook,   I get all the values of field and do  add to $document using addField api. With this values are indexed and I can search, I get the search result perfect. <br>

<br></div>Just for example purpose, say field name is <b>skillset</b> (it&#39;s a multi value field).<br><br></div>Say initially I added, Java, PHP, MySQL, Drupal, C++ as skill sets to skillset field as separate separate values.<br>

<br></div>If I search for PHP + MySQL + C++, I get this document. So far so good.<br><br></div>Say after 1 month, user came and removed C++ skill set. Then in index, for skillset field the corresponding change should happen. That is first all old values should be removed, next Java, PHP, MySQL, Drupal should added only.<br>

<br></div>Today I do not know how to remove a field&#39;s old values, Can somebody help me to find out how do I remove old datas for that particular field (skillset). Today what is happening, I go and add again. Now the resultant data for skillset becomes Java, PHP, MySQL, Drupal, C++, ava, PHP, MySQL, Drupal. Hence if I search c++, I get this document in search which is wrong.<br>

<br></div>Please somebody help me or give me pointer how to delete the old data for a field in index.<br><br></div><div>Please note that in case of single-value field this issue would not arsie.<br></div><div><br></div>Thanks<br>

kamal<br></div>Net Cloud Systems<br><div><div><div><div><div><br><br><br></div></div></div></div></div></div>
</blockquote></div><br></div>