Forum Discussion

gouletf's avatar
gouletf
Copper Contributor
Feb 15, 2023

Obtain search facet results for managed attributes

Hello,

 

Using the catalog api, is there a way to query and obtain search facet results for a particular managed attribute (businessAttributes in the api specs)  ?

 

My query is similar to this one but I would like to add a managed attribute in the facets array of the search request.

https://learn.microsoft.com/en-us/rest/api/purview/catalogdataplane/discovery/query?tabs=HTTP#discovery_query_facet

 

Thanks !

 

2 Replies

  • AlejandroPinon's avatar
    AlejandroPinon
    Copper Contributor

    Hello,
    I achieved it by using the filter in this way:
    {
    "attributeName": "<ManagedAttributeGroupName>.<ManagedAttributeName>",
    "operator": "eq",
    "attributeValue": "<value>"
    }

    Further info:
    https://learn.microsoft.com/en-us/rest/api/purview/catalogdataplane/discovery/query?tabs=HTTP#discovery_query_businessmetadataattribute

    • gouletf's avatar
      gouletf
      Copper Contributor
      Hello Alejandro,
      This will only filter the Array of SearchResultValue. I need to have managed attributes in the search_facets?: SearchFacetResultValue of SearcResult. Thanks anyway.

Resources