Expand my Community achievements bar.

SOLVED

Container or OR operator to create recommendations collection

Avatar

Level 3

Hi folks,

I need to build a recommendations collection for French food pages with a mix of content with unlike metadata. Say I have two content types but they do not share a common field with the same value; one has subjects and one has cuisine e.g.

Category EQUALS food AND
[Subjects CONTAINS french OR france OR
Cuisine EQUALS french ]

How can I build a collection that gets this content without an OR operator, or a container? Alternatively, can I create two separate collections and combine them somehow?

 

PS I cannot edit the meta values.

 

Thanks

Keith

 

Topics

Topics help categorize Community content and increase your ability to discover relevant content.

1 Accepted Solution

Avatar

Correct answer by
Employee

Hi @KeithDavo,  I'd suggest creating a new column in the feed as a flag of sorts, like "isFrench=true", and using that to create a collection.

View solution in original post

3 Replies

Avatar

Level 5

Hi @KeithDavo,

If you navigate to 'Catalog Search' and select 'Advanced Search, ' you can use this area to build your collection. 

 

  1. Build the first part of your rule:
    • Attribute name: 'Category'
    • Operator: 'equals'
    • Operands: 'food'
  2. Then, click '+ Add Rule' 
  3. Now build the second part of your rule:
    • Attribute name: 'Subject'
    • Operator: 'contains a substring'
    • Operands: 'french, france' (separate each value with a comma)
  4. Then, click '+ Add Rule.' (again)
  5. Now build the third part of your rule:
    • Attribute name: 'Cuisine'
    • Operator: 'equals'
    • Operands: 'french'
  6. Now, you can validate that the expected products appear in the list below the filters/rules.
  7. If you see all the "products" as expected, click 'Save As...' and select 'Collection'
  8. Enter the name of your collection and click 'Create' 

 

You should now have a collection with the required items.

 

I hope that helps you out. Please let me know if you need more info.

Avatar

Level 3

Thanks Matthew, but I need the last operator (step 4.) to be OR.

One of the content types only has Subject value (french, france) and the other only has Cuisine value (french). I want to collect both content types but they don't share a common french value.

grouped-and-collection-rules.png

 

 

Avatar

Correct answer by
Employee

Hi @KeithDavo,  I'd suggest creating a new column in the feed as a flag of sorts, like "isFrench=true", and using that to create a collection.