PIMinRiver

inRiver

Entity Relations

inRiver gives a possibility to retrieve related entities together with the source entity and use them in Sana. The fields from the entities can be used for search, filtering using facets, creating product sets and for product specifications in Sana.

The inRiver add-on does not retrieve all related entities automatically, as it may affect performance. Therefore, you need to create a server setting and specify all related entities which must be retrieved by Sana.

For example, the entities you need to retrieve are linked in the following way:

               Source entity: Product
                         Inbound/Outbound entity: ProductDetails (Link Type Id: ProductDetails)
                         Inbound/Outbound entity: ProductAttributes (Link Type Id: ProductAttributes)
                                Inbound/Outbound : Size (Link Type Id: ProductSize)
                                Inbound/Outbound: Color (Link Type Id: ProductColor)

In this case, Product is a source entity, ProductDetails and ProductAttributes are related entities linked to the Product source entity and Size and Color are related entities linked to the ProductAttributes related entity. All fields from the Size and Color related entities will be retrieved and used for products in Sana.

To create a server setting you need the Link Type Ids of the related entities.

To create a string for the server setting, you need to stick to the format. You should combine the relations into a string in the correct order, separating them with a semicolon (;). To add a related entity linked to another entity, you need to combine the IDs of entities, separating them with a period (.).

In this case, the string will look in the following way: ProductDetails; ProductAttributes; ProductAttributes.ProductSize; ProductAttributes.ProductColor

In this way, the ProductDetails and ProductAttributes related entities will be retrieved together with the Product source entity, and the ProductSize and ProductColor entities will be retrieved with the ProductAttributes related entity.

Step 1: Go to the Settings in the inRiver Control Center. Since Product is a source entity, then it will be used to create a key for the server setting: SANA_PRODUCT_RELATIONS. In the value of this server setting enter the string you have created.

The server setting should look in the following way: the key is SANA_PRODUCT_RELATIONS and the value is ProductDetails; ProductAttributes; ProductAttributes.ProductSize; ProductAttributes.ProductColor.

Step 2: When the server setting is created, you need to rebuild the product index. Open Sana Admin and click: Tools > Scheduled tasks. Run Rebuild index for the Product import task. Then, refresh the site cache.

PIMinRiver