Field name priority
As it is possible to ingest products and SKUs with arbitrary field names through the use of sku attributes and product metadata, it is possible to create a field with the same name as another field.
This should be avoided, since requests which only use the field name of a field, such as search request filters, will be ambiguous. To resolve the ambiguity, Ecommerce Search has an inbuilt priority on which SKU or product field requests will refer to.
Example
By accident, a field with the field name Url
has been added to both StringAttribute
and Metadata
. On the search scope, Url
has been added, expecting the URL value from Metadata
to be returned. The returned URL, however, is incorrect, as StringAttribute
has a higher priority than Metadata
.
The priority list, in order of highest to lowest priority, is as follows:
- Product
SearchableIds
- Product
AlternativeSearchWords
- SKU
SkuEan
- SKU
SkuNo
- Product
ProductNumber
- SKU
SkuId
- Product
ProductId
- SKU
SkuName
- Product
ProductName
- Product
CategoryNames
- Product
CategoryIds
- Product
Categories
- Product
ShortDescription
- Product
LongDescription
- Product
Price
- Product
PriceGroup
- Product
Inactive
- SKU
Stock
- SKU
StringAttribute
- SKU
NumberAttribute
- SKU
IntervalAttribute
- SKU
Metadata
- Product
Metadata
- Product
Media