A Magento EE 220.127.116.11 site I'm working on was having problem with target rules. The rule would be something very simple, like this:
Products to Match: If ALL of these conditions are TRUE: Category is 10 Products to Display: If ALL of these conditions are TRUE: Product Collection contains Matched Product Collection
Now "Collection" is a custom attribute that we created (attribute code is
collections.) It's a multiselect, with a scope of "Store View". We also imported the nearly 1000 options for that attribute, and over 10,000 attribute-to-product values. When we imported these values, we set the
store_id to 1.
I should note that we only have one website (ID: 1) one store group (ID: 1) and one store view (ID: 1) so setting the
store_id to 1 in
catalog_product_entity_value seemed okay.
We noticed that the subselect that the Target Rule module creates has
store_id = 0 in it though, and that no products ever matched based on this
collections attribute. It wasn't until we changed all of the values in
catalog_product_entity_value to have
store_id = 0 that this Target Rule started working.
There isn't even a means to select a store view in the admin because we only have one on the site, and there are thousands of attribute values in
catalog_product_entity_value with a
store_id of 1, so why must I set this particular attribute to 0 to get it to work?