Jump to content

Search products by product_code


Recommended Posts

Hi,

 

Half of the products on my site have different size.

I.E. : i have boots, and, as you know, they come in different sizes, from 39 to 45.

 

size 39 has assigned the product code ABC39

size 40 has assigned the product code ABC40

------

------

------

size 45 has assigned the product code ABC45.

 

Let's assume the default size for the boots is 39, so the product code will be ABC39.

 

My problem is:

 

 

When i search on front end for the code ABC39 (which is, I repeat, the main product code) i get the desired product as a result for my search query.

 

But now comes the problem: when i search for ABC40 (which is the code for size 40) i get no result.

How can i get results after searching for codes such as ABC40?

 

Thank you!

Link to comment
Share on other sites

I have attached a few images that will explain in detail my issue.

 

I have a single product, with more combinations (the boots have different sizes, from 39 to 45).

Each size has a different code assigned.

 

The default code for the boots it LAB00179.

When i search for LAB00179 the boots are returned as a result. But when i search for LAB00181 i get no result at all.

 

What i need is to get results after i search for codes such as LAB00181.

How can i accomplish that?

 

post-42763-0-72650000-1329082216_thumb.jpg --> this is the default size of the product

 

post-42763-0-73493700-1329082233_thumb.png --> these are the product's combinations

 

post-42763-0-15455400-1329082225_thumb.png --> this is a random size of the product, which needs to be returned as a result after searching for the assigned code.

Link to comment
Share on other sites

Hmm... you are right, there is a bug. References assigned to combinations are not indexed but instead the reference entered in the info tab is indexed for combinations too. First file a bug report. You can simply point to this forum thread in bug description.

 

Bug info:

-----------

Reference assigned in info tab of a product

References assigned to combinations

Indexed result

------------

 

Meanwhile, you can use this bug for your purposes. Here is what you can do. For the main product specify a reference like LAB00197 - 00 (or more digits if you have more than 99 combinations). Then for each combination assign a reference by increasing the last two digits by one. LAB00197 - 01, LAB00197 - 02 etc.

 

Now because of the (buggy) way references are indexed, when you search for LAB00197 - 05 (or just LAB00197) you will have a hit on LAB00197 - 00.

 

screen capture

screen capture

screen capture

screen capture

screen capture

Link to comment
Share on other sites

  • 2 weeks later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...