Gravatar for bkumar@littelfuse.com

Question by Bharath, May 9, 2019 5:57 AM

FacetOn method is not returning numeric values

Hi Sir,

I have one Numeric facet, but below is not returning results. I can see numeric facet values in Coveo admin tool

//PartsProperties is the list of facets
foreach (var property in oSearchByParameter.PartsProperties)
{
  var property1 = property;
  oCurrentFilters = oCurrentFilters.FacetOn(f => f[property1.PartPropertyName], 1);
}

Thanks,

Bharath

Gravatar for bkumar@littelfuse.com

Comment by Bharath, May 13, 2019 9:59 AM

Hi Sir,

i have added below facet in config file

<fieldTypefieldName="ATestFacet"isSortable="true"type="System.Int32"returnType="System.Int32"isFacet="true"includeForFreeTextSearch="false"isMultiValue="true"settingType="Coveo.Framework.Configuration.FieldConfiguration,
Coveo.Framework" />

<field fieldName="ATestFacet" PropertyName="ATestFacet" PropertyDisplayName="ATestFacet" FacetReturnType="Integer" >Littelfuse.Coveo.ComputedFields.PartGenericCharacteristicFacet,
Littelfuse.Coveo</field>

returning as numerc type from computed index

public PartGenericCharacteristicFacet(XmlNode configNode): base()<br>{<br>PropertyNames = XmlUtil.GetAttribute("PropertyName", configNode, true);<br>ReturnType = XmlUtil.GetAttribute("FacetReturnType", configNode, true) ?? "string";<br>}

And also added facet in the system/settings/bucket/facets.

The facet Field is not showing up in coveo facet dropdown options, but it displays on coveo facet slider field dropdown.

Thanks,

Bharath

0 Reply
Ask a question