Hi,
Thanks.

1. Although I do set q I don't see q overwritten so it's processed with
new setting though.
Example I add aaaaaaaa... to the query and here what I debug of q     in
log/catalina.out

Qparam: germanyaaaaaaaaaaaaaaaaaaa
Jun 26, 2009 10:00:37 AM org.apache.solr.core.SolrCore execute
INFO: [] webapp=/blah-en path=/select/
params={fl=*&q=germany&qt=dismax&rows=43} hits=492 status=0 QTime=516


>From what I see in INFO  the q=germany and NOT       
q=germanyaaaaaaaaaaaaaaaaaaa as I would expect. So real query executed
is still original q.

Is there some other point that I should plug into or another way to set
the param?

2. On side note. SearchHandler is too generic as I get stuff like this
during start of tomcat.

Qparam: static firstSearcher warming query from
solrconfig.xmlaaaaaaaaaaaaaaaaaaa

which seems like internal queries also pass through
SearchHandler::handleRequestBody() That is not that great of issue..I
can  just pass extra command and process only those (making sure it's my
query).


I reallize those seems small questions and probably sound stupid but I
just cannot find manual howto handle those properly.


Mark Miller wrote:
> Julian Davchev wrote:
>> Mark Miller wrote:
>>  
>>> Rather than using org.apache.solr.request.SolrParams, try using
>>> org.apache.solr.common.params.SolrParms.
>>>
>>>     
>> Thanks that really helped. One final issue to solve.    I don't see
>> SolrParams.set()     which I guess is normal but how can I
>> modify the q param before I pass it further for processing.
>> Basically I got...
>>
>>         SolrParams p = req.getParams();
>>         String words = p.get("q");
>>         //do something with words....                   //assign
>> words back to q param so that the processing is on
>> modified q?  What is recommended way to do this?
>>
>> Thanks
>>   
> You might try:
>
> SolrParams p = req.getParams();
> String words = p.get("q");
> ModifiableSolrParams newParams = new ModifiableSolrParams(p)
> newParams.set("q", words + stuff);
> req.setParams(newParams);
>
>

Reply via email to