3

Magento seems to create a product_price_index row for each product X customer_group_id even if a given customer_group_id doesn't have a price for the product.

This ends up in a problem such: I have 4675 products and 285 customers. A given customer might only have 1 special price for 1 product, and no more, but still I get 4675x285 = 1332375 rows in the index, which thus becomes un-manageable, making each reindex a real pain.

Does any one out there have any ideas about how to handle this situation?

Has somebody implemented any solution for this situation?

2

If you add store and website views into the mix you'll see an even larger number of rows.

Unfortunately this is a by product of Magento's flexible pricing schema.

I'd recommend upgrading to 1.8.x CE or 1.13.x EE if you are not on the latest release, as some fixes have been made around this specific issue:

Catalog price rules are applied properly to customer groups.

What those specifics are I'm not entirely sure.

If upgrading isn't an option:


EDIT

Here are a few things to help out with performance of Magento and Indexing via Asynchronous Indexing, Disabling unused Core Modules and Logging as well as a Class Path Cache. All of which should improve indexing performance with minimal cost/time, and without upgrading Magento.

Disable logging and any unused core modules you don't use:

Some modules to consider when needing more insight into the indexing/caching mechanisms:

Improve Index management in Magento. Enables Magento to process indexes asynchronously. I would highly recommend giving this a try as it will chunk up the data needing to be indexed and spawned across separate PHP processes. By Default Magento only uses one CPU Core when indexing. On a large multi-core system this helps tremendously with indexing performance.

Another free option available on GitHub that looks to be more up to date:

There is a paid for solution as well, as Aoe_Index hasn't been updated in over 4 years.

With as many files/folders that Magento has, this helps the Autoloader find the exact files its looking for instead of fseek's on your servers file system to locate the files. Not a direct solution to your problem but will greatly speed up Magento's performance.

  • Already in 1.8.0.0. CE... so upgrading is definetely no t a solution, plus, EE is not an option as suggested in your last link. I just wonder if all those lines just replicating product price are really necessary. It would be easier if there was a fallback to product's price whenever there's not a row for a given customer group. I hope someone developed a solution with this in mind – Jared Dec 10 '13 at 10:13
  • Of course, FPC, etc are going to be considered but that doesn't solve the problem, just makes it more expensive. – Jared Dec 10 '13 at 10:15
  • @Jared Updated answer with option(s) to try. – B00MER Aug 17 '16 at 19:12
  • 1
    I appreciate your help. The thing is that I don't have anything to do with that project anymore so I cannot try or implement the solutions you provided. Thank you anyway – Jared Aug 24 '16 at 8:37

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.