tags:

views:

600

answers:

1

Hi,

i want to filter faceting counts on a multi valuated field (no docs)

For example:

select?q=*:*&rows=5&facet=true&facet.limit=5&facet.field=productID&facet.sort=true

is there any chance to filter counts on my facet.field productId ?

Given the previous query what i get is:

<lst name="facet_counts">
<lst name="facet_queries"/>
−
<lst name="facet_fields">
−
<lst name="productID">
**<int name="EG7SpTw03mJ25vxS5jcB24">603</int>**
<int name="E53OBaX5hjGDAKzbHHaDG1">573</int>
<int name="sSLMrsA0wjLF8iWRAbzNq4">415</int>
<int name="ijcfPOTpg3eeGoXSW8h8L5">336</int>
<int name="Lij0a3kVgQzLxtOMgOXb06">296</int>
</lst>
</lst>
<lst name="facet_dates"/>
</lst>

I just want to filter the query to get results like:

− − 603 573 415 336 296

 <lst name="facet_counts">
    <lst name="facet_queries"/>
    −
    <lst name="facet_fields">
    −
    <lst name="productID">
    <int name="E53OBaX5hjGDAKzbHHaDG1">573</int>
    <int name="sSLMrsA0wjLF8iWRAbzNq4">415</int>
    <int name="ijcfPOTpg3eeGoXSW8h8L5">336</int>
    <int name="Lij0a3kVgQzLxtOMgOXb06">296</int>
    <int name="Lij0a3kVgQzLxtOMYERESW">293</int>
    </lst>
    </lst>
    <lst name="facet_dates"/>
    </lst>

Just want to filter by productId:EG7SpTw03mJ25vxS5jcB24 ...

THX

+1  A: 

Well, i found the solution, it's just use the facet.prefix parameter

select?q=:&rows=5&facet=true&facet.limit=5&facet.field=productID&facet.sort=true&facet.prefix=EG7SpTw03mJ25vxS5jcB24

The output i get is :

<lst name="facet_counts">
<lst name="facet_queries"/>
−
<lst name="facet_fields">
−
<lst name="taxonUUID">
<int name="EG7SpTw03mJ25vxS5jcB24">603</int>
</lst>
</lst>
<lst name="facet_dates"/>
</lst>

I'm gonna make a new more complex question about this topic ...

Lici