Magento – configurable products are not showing up in the front end (catalog and search pages)

configurable-productmagentomagento-1.7

My configurable products are not being shown on the front end. On the backend, Magento seems to list the configurable products as 0 inventory (although there is no input box for quantity amount for a configurable product).

  1. all of their products are set to "in stock" and have quantities above zero
  2. the configurable products themselves are also set to "in stock" [there is no setting for quantity – as mentioned above]
  3. data is re-indexed and caches have been flushed
  4. Using Magento 1.7.0.2
  5. Using the popular extension Simple Configurable Products here

please advise…

Best Answer

Here is the solution that worked for me:

the problem is with the code used in Simple Configurable Products (OrganicInternet)

I would like to note that I was having two seperate issues at once - the above, and the product price index refused to be indexed (I was recieving this message: Cannot intialize the indexer process, which was explained as SQLSTATE[21S01]: Insert value list does not match column list: 1136 Column count doesn't match value count at row 1)

as it turned out both problems were related, and below solved them both ;)

  1. in the file / app / code / community / OrganicInternet / SimpleConfigurableProducts / Catalog / Model / Resource / Eav / Mysql4 / Product / Indexer / Price / Configurable.php

change:

$select->columns(array(
        'entity_id'         => new Zend_Db_Expr('e.entity_id'),
        'customer_group_id' => new Zend_Db_Expr('pi.customer_group_id'),
        'website_id'        => new Zend_Db_Expr('cw.website_id'),
        'tax_class_id'      => new Zend_Db_Expr('pi.tax_class_id'),
        'orig_price'        => new Zend_Db_Expr('pi.price'),
        'price'             => new Zend_Db_Expr('pi.final_price'),
        'min_price'         => new Zend_Db_Expr('pi.final_price'),
        'max_price'         => new Zend_Db_Expr('pi.final_price'),
        'tier_price'        => new Zend_Db_Expr('pi.tier_price'),
        'base_tier'         => new Zend_Db_Expr('pi.tier_price'),
    ));

to:

$select->columns(array(
        'entity_id' => new Zend_Db_Expr('e.entity_id'),
        'customer_group_id' => new Zend_Db_Expr('pi.customer_group_id'),
        'website_id' => new Zend_Db_Expr('cw.website_id'),
        'tax_class_id' => new Zend_Db_Expr('pi.tax_class_id'),
        'orig_price' => new Zend_Db_Expr('pi.price'),
        'price' => new Zend_Db_Expr('pi.final_price'),
        'min_price' => new Zend_Db_Expr('pi.final_price'),
        'max_price' => new Zend_Db_Expr('pi.final_price'),
        'tier_price' => new Zend_Db_Expr('pi.tier_price'),
        'base_tier' => new Zend_Db_Expr('pi.tier_price'),
        'group_price' => new Zend_Db_Expr('pi.group_price'),
        'base_group_price' => new Zend_Db_Expr('pi.group_price'),
    ));

and

$outerSelect->columns(array(
        'customer_group_id',
        'website_id',
        'tax_class_id',
        'orig_price',
        'price',
        'min_price',
        'max_price'     => new Zend_Db_Expr('MAX(inner.max_price)'),
        'tier_price',
        'base_tier',
        #'child_entity_id'
    ));

to

$outerSelect->columns(array(
        'customer_group_id',
        'website_id',
        'tax_class_id',
        'orig_price',
        'price',
        'min_price',
        'max_price'     => new Zend_Db_Expr('MAX(inner.max_price)'),
        'tier_price',
        'base_tier',
    'group_price',
    'base_group_price',
        #'child_entity_id'
    ));

source: main issue together with this (however please note that the correct code is 'base_group_price' => new Zend_Db_Expr('pi.group_price'), and not 'base_group_price' => new Zend_Db_Expr('pi.base_group_price'),

  1. also, in the file: / app / code / community / OrganicInternet / SimpleConfigurableProducts / Catalog / Model / Resource / Eav / Mysql4 / Product / Indexer / Price.php

change

$this->cloneIndexTable(true);

to

$this->clearTemporaryIndexTable();

source: here

It took me several hours to figure this out so I wrote this post to help anyone else from wasting all that time.

best of luck!

Related Topic