Last active
December 20, 2015 03:59
-
-
Save agilejon/6067542 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var solr = SolrProxy.GetConnection<IndexedClip>(); | |
var field = new SolrQueryByField("d_OFF FORM", "Pro"); | |
var options = new QueryOptions { | |
Facet = new FacetParameters { Queries = new[] { | |
new SolrFacetQuery(new SolrQueryByRange<int>("dist", 0, 3)), | |
... | |
new SolrFacetQuery(new SolrQueryByRange<string>("dist", "10", "*")) | |
} } | |
}; | |
var results = solr.Query(field, options); | |
foreach (var facet in r.FacetQueries) { | |
Console.WriteLine("{0}: {1}", facet.Key, facet.Value); | |
} | |
foreach (var result in results) { | |
Console.WriteLine(result.ClipId); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment