What is the purpose of table spy_product_search_attribute_map?

sebastian.larisch
sebastian.larisch Spryker Customer Posts: 143 🧑🏻‍🚀 - Cadet

Is anyone using spy_product_search_attribute_map and can explain to me the benefit of that table? Docs saying it maps product attributes to their corresponding search keys. I would like to understand it and how we could use it.

Some background: We had some attributes in that table and were wondering why we have duplicate string-facets on some products.

Answers

  • fsmeier
    fsmeier Senior Software Engineer & Developer Enablement Advocate Sprykee Posts: 1,051 ⚖️ - Guardians (admin)

    Heyhey,
    sorry for the late reply but it took some time to gather some information.

    It enables the ability to make a product searchable based on its attributes without needing code modifications. It functions seamlessly in conjunction with 'spy_product_attribute_key'.

    1. Not all attributes are included to search preferences by default if you search through product data.
    2. You need to re-publish all entities after this manipulation. There is somewhere a button in Back Office /product-search/search-preferences
    3. The benefit: Admin can manage it by him/herself without a developer.

    Does this help?

    All the best,

    Florian

  • sebastian.larisch
    sebastian.larisch Spryker Customer Posts: 143 🧑🏻‍🚀 - Cadet

    Hey @fsmeier ,

    thanks, I finally understood and also made some tests on my local env. This table is used to map an attribute to for example the full_text_boosted field. With that it is possible to search for these attribute values and find related products. It can be configured (as you said) in the backend at  /product-search/search-preferences. Thanks.