문제

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?

도움이 되었습니까?

해결책

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.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 magento.stackexchange
scroll top