Erik Hatcher wrote: > Ron - I think SOLR-792 meets the need you describe. What do you think? > It's "tree faceting", allowing you to facet down 2 levels deep > arbitrarily on any two fields. Ideally we'd enhance it to be of > arbitrary depth too.
Nice! It certainly handles my main use case. There are still a couple cases that would benefit from a more flexible function returning data along with the facets. In this app, each document represents a crime report describing, for example, an auto theft. Those documents have fields such as the make & model of a car stolen. In some cases the users would like to see numbers showing the number of incidents involving cars of those types (which I think is what Solr returns easily). Sometimes instead of the number of documents, they'd rather see the number of cars involved - for example, if a single theft from a dealership involved multiple cars. And other times, they'd rather see the value of the cars returned. In SQL I can do a "select sum(value) from incidents join vehicles...", and haven't (yet) found similar for facets in solr. Then again, maybe I should be using the database for that part.... > On Feb 24, 2010, at 6:40 PM, Ron Mayer wrote: >> .... >> Make >> FORD GM Honda TOYOTA [....] >> MONDAY 17 23 4 2 >> TUESDAY 11 9 174 5 >> WEDNESDAY 3 6 9 1