[英]How to query in solrNet
I am new to solrnet . 我是solrnet的新手。 i need to Pass this url to solr to my "pharmaSearch" requestHandler and i need to get the result xml .
我需要将此URL传递给我的“pharmaSearch”requestHandler,我需要获取结果xml。 guide how to do this in solrNet(Now for the url it is working in brower) where else i need to call this from .net application
指导如何在solrNet中执行此操作(现在为url工作在brower中)我还需要在.net应用程序中调用它
http://localhost:9090/solrSDIS/study/pharmaSearch/?&Eq=(A*B*C)&ExpTerm=A,B,C&QueryLevel=2,2,1&q=526:(27747) AND (1028:[10 TO 27]) AND (469:[-10 TO 742]) AND 523:("Body Weights") AND 262:n , (518:"27058") AND (430:((Necrosis))) AND 523:("Microscopic Findings") AND 262:n ,(169:"7631")&scope=2 Let me know if you need any details ... http:// localhost:9090 / solrSDIS / study / pharmaSearch /?&Eq =(A * B * C)&ExpTerm = A,B,C&QueryLevel = 2,2,1&q = 526:(27747)AND(1028:[10 TO 27]和(469:[ - 10至742])和523 :(“体重”)和262:n,(518:“27058”)和(430:((坏死)))和523 :(“微观调查结果“)和262:n,(169:”7631“)&scope = 2如果您需要任何细节,请告诉我......
Advance Thanks . 提前谢谢。
You can pass the name of your handler by using the ExtraParams parameter in the QueryOptions as shown in the addition parameters section here: 您可以使用QueryOptions中的ExtraParams参数传递处理程序的名称,如此处的“添加参数”部分所示:
http://code.google.com/p/solrnet/wiki/Querying http://code.google.com/p/solrnet/wiki/Querying
...
ExtraParams = new Dictionary<string, string>
{
{"qt", "paramSearch"},
{"Eq", "(A*B*C)" },
...
}
...
You can build up a fluent query as shown in the documentation for solrnet here: 您可以在此处建立一个流畅的查询,如solrnet文档中所示:
http://code.google.com/p/solrnet/wiki/DSL http://code.google.com/p/solrnet/wiki/DSL
... Query.Field("523").Is("Body Weights") && Query.Field("469").From(-10).To(742) && ...
The documentation contains everything you need to compose your query. 该文档包含撰写查询所需的一切。
You need to read the documentation on the SolrNet Google Code Home Page - http://code.google.com/p/solrnet to learn the basics of using SolrNet so that you can map your solr rest query above to the appropriate SolrNet syntax. 您需要阅读SolrNet Google Code主页上的文档 - http://code.google.com/p/solrnet,以了解使用SolrNet的基本知识,以便您可以将上面的solr rest查询映射到相应的SolrNet语法。
I would suggest starting with the Basic Usage page as this gives a very nice sample of executing a search against solr. 我建议从Basic Usage页面开始,因为这给出了一个非常好的样本,可以对solr执行搜索。 Then you can leverage the answer above by @SteadyEddi to call your custom request paraeters.
然后,您可以利用@SteadyEddi上面的答案来调用您的自定义请求paraeters。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.