How to configure search by reference (SKU, DIN, ISO) on a B2B e-commerce site?
A buyer types "M8x20." The engine searches for "M8x20" exactly. Your database has it stored as "M8 x 20." Result: zero matches, even though the product is in stock.
On a general consumer catalog, keyword search is usually enough: a visitor types "red dress," the engine finds red dresses. On a technical B2B catalog, the problem is different — the buyer isn't searching for a category, they're searching for an exact reference: a screw designation, a standard, a supplier code.
Why keyword search fails on technical references
Default search engines split text word by word (called tokenization) and look for matches between those tokens. This works well for natural language, but poorly for structured strings like M8x20 or DIN 933.
The problem comes from format variation: the same reference might be stored as DIN933, DIN-933, or DIN 933 depending on who filled in the product sheet, and the query a customer types rarely matches that exact format. The engine doesn't make the connection — to it, these are different strings.
The fix: regular expressions and normalization
Two complementary mechanisms solve this problem:
- Query normalization before indexing: spaces, dashes, and casing are standardized in both the catalog and the typed query before any comparison happens.
DIN-933,DIN 933, anddin933become equivalent. - Regular expressions (regex): they let the engine recognize a reference format (for example, a metric screw designation) and extract its relevant components — diameter, length, standard — rather than comparing text character by character.
In practice, a customer typing a partial or slightly mis-formatted reference still finds the right product, because the engine understands the structure of the reference rather than just comparing characters.
A professional buyer who can't find a reference they already know doesn't keep looking on your site — they go to a competitor.
How to assess your own situation
A simple test: take five references from your catalog, type them into your search engine with a slightly different format than the one stored (extra space, missing dash, different casing). If more than one out of five fails, this is worth an audit — it's a structural configuration issue, not a content gap.