Book Image

Solr Cookbook - Third Edition

By : Rafal Kuc
Book Image

Solr Cookbook - Third Edition

By: Rafal Kuc

Overview of this book

Table of Contents (18 chapters)
Solr Cookbook Third Edition
Credits
About the Author
Acknowledgments
About the Reviewers
www.PacktPub.com
Preface
Index

Implementing the autocomplete functionality for products


Recently, the autocomplete functionality has gained popularity. You can find it in on Google, Bing, and many more similar e-commerce sites. It enables your users or clients to find what they want and do it fast. In most cases, the autocomplete functionality also increases the relevance of your search by pointing to the right author, title, and so on right away without looking at the search results. What's more, sites that use autocomplete reported higher revenue after deploying such a functionality compared to the situation before implementing it. It is a win-win situation both for you and your clients. So let's take a look at how to implement the product autocomplete functionality in Solr.

How to do it...

Let's assume that we want to show you the full product name whenever our users enter part of the word that the product name is built of. In addition to this, we want to show you the number of documents with the same names.

  1. Let's start...