Question

I have 300+ "Category" (Can go into 4 sub levels) items and 1Mn+ "Product Items" to be stored in the Sitecore database. I am designing the Sitecore content tree.

I am considering two options,

Option1 - Model as "Category" --> Sub category .... --> "Product Items"

Option 2 - Model "Category" tree separately and have "Product Items" separately. (Home -> Categories -> cat 1...) and (Home -> Product Items -> All Product Items)

According to my experience if I go for option 1, it will be painfully slow if I need to modify the category items and publish. (Even with some enhancements)

Option 2 does not create a well balanced tree, but the category nodes will be much faster to edit.

Please help me to sort out this. I am using Sitecore 7.

Was it helpful?

Solution

You are more or less going to have to come up with a solution for storing your in a separate section of the content tree. I would most definitely not advise you to place a million+ product items sitting directly under the individual category items. For a number of reasons, including:

  1. Performance, as you say. Changes to categories will happen often, to "follow the market", for "seo reasons". Also "campaign categories" (like "Summer Sale 2014") is bound to pop up from time to time
  2. The nature of a category/product relationship is very rarely 1 to 1. Meaning the same product can and will exist in multiple categories (think: Duracell batteries existing in both "Electrical", "Batteries - Non-rechargeable" and "Camera Accessories" categories)

Since you're on Sitecore 7, the built-in solution for your product repository is to put all the products into an Item Bucket. Then you have two (obvious) choices for Building the product/category relationship:

  1. On "Product", set up a Multilist field named "Categories", and add the ID of each Category item the product belongs to
  2. On "Category", set up a search field to select products from your Item Bucket

It really depends on how this product hierarchy is going to be managed, which of the above fits best.

Information on Item Buckets here: http://sdn.sitecore.net/Reference/Sitecore%207/Developers%20Guide%20to%20Item%20Buckets%20and%20Search.aspx

OTHER TIPS

Solution 1 is still the best one in my opinion.

It always better to create a comprehensive and logical store as "bath and shower articles in the bathroom category" than having products in both categories and no categories.

The global benefit having categories for products is for indexing (as for human, as for your website, as for search engine )

With some CMS like Magento , you easily manage 1M products with categories, and you can edit , move categories as you want, so to finish my answer , yes answer1 is the most suitable answer to me :)

Edit : Sorry i didn t see you re already using sitecore

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top