Posting in the Magento forums has been disabled pending the implementation of a new and improved forum solution which should better serve the community.

For new questions please post at magento.stackexchange.com, the community-run support site for the Magento community. We will be providing updates on the new forum solution soon. For questions or concerns please email community@magento.com.

Magento Forum

advanced search on dropdown product attributes returns no results
 
dkoo761
Jr. Member
 
Total Posts:  8
Joined:  2008-10-10
 

Hey everyone,

I currently have 2 stores running in 1 instance of Magento 1.1.6. I have imported a few hundred products so far into 1 of the stores (I specified the particular store & website as columns in my import file). The products themselves appear to have imported just fine. All the fields are correct and the products appear on the storefront.

The problem I’m having is that the products don’t appear if I do an advanced search using one of the dropdown product attributes that I added. For example, I have a dropdown attribute called “sport” in the Advanced Search page where a shopper can choose which sport they are interested in (ie. Baseball, Football, etc). When they choose a sport from the dropdown box (leaving all other search fields blank) and click Search, there are no results found although many such products exist in the catalog. When I go into the catalog via the Magento admin panel to check the products, they all have the correct value for the Sport attribute.

After staring at the database for a while, the problem appears to be that after an import finishes, no records are inserted into my catalogindex_eav table. So basically downdown product attributes aren’t getting indexed since they are supposed to be stored in this table, from what I can gather. I have some other varchar product attributes which produce search results correctly. If I manually insert a record into this DB table, everything works fine, but I’m not going to manually insert thousands of records into this table smile

So as it stands right now, my catalogindex_eav table is ALWAYS empty (as are my catalogindex_minimal_price and catalogindex_price tables). I suppose I could write my own script to populate these tables after doing an import, but I’d rather not have to do that since this is a feature that is supposed to work out of the box in Magento and I’m probably just doing something wrong smile

There are a couple other things I’ve discovered.

1) The problem only exists for products I import into Magento. If I create the product via the Magento admin interface, no problem!

2) The problem only exists on my hosting environment (Crucial Web Hosting), not on my local dev environment. So it must be something to do with the differences in my Magento configuration or hosting setup (although I can’t find anything that might be causing this).

3) After importing a product, if I edit it via the Magento admin interface and save it (without making any changes), then search works fine. However, if I import that same product again afterwards, it deletes the record from catalogindex_eav and the problem comes back again.

I’d greatly appreciate any help from you guys & gals! smile

Thanks,
Dave

 
Magento Community Magento Community
Magento Community
Magento Community
 
nuranto
Member
 
Total Posts:  35
Joined:  2008-09-30
 

Hi,

I have exactly the same issue, have you found a solution ?

Thanks,

Vincent

 
Magento Community Magento Community
Magento Community
Magento Community
 
Itosa
Member
 
Total Posts:  39
Joined:  2009-07-02
 

Hello,

Any solutions??

itosa

 
Magento Community Magento Community
Magento Community
Magento Community
 
peteror
Jr. Member
 
Total Posts:  17
Joined:  2009-05-16
 

Hi,

I was wrestling with this issue as well, found this script that neatly rebuilds the catalog indexes (for some reason the ‘rebuild catalog indexes’ button in the admin did not work at all to this effect)

Tested with Magento 1.3.2.4

<?php

$magePath = '../app/Mage.php'; //or whatewer your path is
require_once $magePath;
//Varien_Profiler::enable();
//Mage::setIsDeveloperMode(true);
//ini_set('display_errors', 1);
umask(0);

Mage::app()->setCurrentStore(Mage_Core_Model_App::ADMIN_STORE_ID);

echo '<h3>Cleaning overall Cache</h3>';

flush();
// clean overall cache
Mage::app()->cleanCache();
echo 'done';

flush();
echo '<h3>Cleaning Catalog Rewrites</h3>';

flush();
// clear 'refresh_catalog_rewrites':
//Mage::getSingleton('catalog/url')->refreshRewrites();
Mage::getModel('catalog/url')->refreshRewrites();
echo 'Catalog Rewrites was refreshed succesfuly<br>';

flush();
echo '<h3>Cleaning Image Cache</h3>';

flush();
// clear 'clear_images_cache':
Mage::getModel('catalog/product_image')->clearCache();
echo 'Image cache was cleared succesfuly<br>';

flush();
echo '<h3>Cleaning Layered Navigation</h3>';

flush();
// clear 'refresh_layered_navigation':
Mage::getSingleton('catalogindex/indexer')->plainReindex();
echo 'Layered Navigation Indices was refreshed succesfuly<br>';

flush();
echo '<h3>Clearing out Search Index</h3>';

flush();
Mage::getModel('catalogsearch/fulltext')->rebuildIndex();
echo 'Search index was rebuilt succesfully<br>';

flush();
echo '<h3>Rebuilding Flat Category</h3>';
Mage::getResourceSingleton('catalog/category_flat')->rebuild();
echo 'flat category was rebuilt successfully<br>';

flush();
echo '<h3>Rebuilding Flat Products</h3>';
Mage::getResourceSingleton('catalog/product_flat_indexer')->rebuild();
echo 'flat product was rebuilt successfully<br>';

flush();

?>

 
Magento Community Magento Community
Magento Community
Magento Community
 
Mage Guru
Sr. Member
 
Avatar
Total Posts:  79
Joined:  2009-07-07
 

The last script runs, but I still have the same problem. Advanced search isnt displaying the right results. Usually it just displays all the products despite the filter..

Any more luck with this on 1.3.2.4?

Thanks

 
Magento Community Magento Community
Magento Community
Magento Community
 
Mirasvit
Guru
 
Avatar
Total Posts:  639
Joined:  2009-08-22
 

Hi

Check out these extensions Search AutoComplete & Suggest Pro. They greatly improve the quality and relevance of search results: http://mirasvit.com/magento-extensions/search-autocomplete-suggestions.html

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top