The Solr Wildcard Problem And Multiterm Solution

A while ago I ran into a problem with Solr and wildcard searches. Turns out it's more of a little known fact than a problem, Solr treats wildcards a bit different than how one would expect.

Normally, when a user enters a search-term we will append '*' to it so it will find words starting with the term that is being searched for. Common sense dictates that when someone searches for "train*", the set of results will also contain the word "train" itself. But "train" is not part of the results. When looking for "train*" Solr will return "trainer", "training", "trains" but it won't return results with the word "train" in it.

In case you want documents matching the exact word as well you will have to change your Solr statement. Instead of searching for "word*" you'll have to look for "word OR word*", only then documents matching "word" will turn up in the result-set.

After discussing it with Nick Veenhof, it turns out that, as of Solr 3.6 there's been a new type of analyser introduced that addresses this shortcoming (although it seems to be more of a side-effect). The multiterm analyser type. Copy the query analyzer section of the text fieldType and change the type to "multiterm". What multiterm addresses is that when you look for "train*" it will run the query as if you've been searching for "train", "trains", "training", "trainer". You might be inclined to think that that's the same as searching for anything that starts with "train", but that is not the case. Without specifying the multiterm analyser the wildcard searches are not analysed at all and thus can't be used for stemming, or downcasing or accent mapping...

Specifying the new multiterm analyser will also "expand" the wildcard search to the actual word, in our case "train", which is what we were looking for.

In case you're using Drupal to interface with Solr there's an issue filed about this along with a simple example explaining the difference between a non-analysed wildcard search and a multiterm search.

Comments

When looking for "train*" Solr will return "trainer", "training", "trains" but it won't return results with the word "train" in it. I am gald to find this article. hi!,I really like your writing very so much! share we keep in touch more about your post on AOL? I require an expert on this house to unravel my problem. May be that’s you! Taking a look ahead to look you. http://www.bestdvdland.com/

Wow..... Really informative blog article.
Spokane Video Weddings

New music instruction commonly starts with elementary educational institutions where little ones are taught the best way to play instruments such as keyboard, play in choirs or maybe school represents, and discover more about the things and heritage of new music. In school, music education may continue as part of the curriculum. neighborhoodacademyofmusic.net

instruction commonly starts with elementary educational institutions where little ones are taught the best way to play instruments such as keyboard, play in choirs or maybe school represents Get Traffic

This is a nice post in an interesting line of content.Thanks for sharing this article, great way of bring this topic to discussion.
SEO Manchester

Merawat printer akan membantu anda memperpanjang usia dari alat cetak ini. Anda bisa mendapatkan spareparts dari printer yang anda inginkan jika anda hanya ingin melakukan perawatan printer. Hanya saja pada umumnya spareparts ini tidak tersedia di tempat umum dan harus dipesan online. sparepart printer murah . lihat perlengkapan printer lainnya di sini kunjungi website kami .
Jika anda ingin melakukan aktifitas wisata yang menyenangkan, maka sebaiknya anda menyewa jasa wisata. Karena anda akan mendapatkan paket wisata yang biayanya ringan dan pelayanannya profesional. Jadi sekarang coba lakukan pemesanan. Paket Wisata Dieng Wonosobo . dapatkan penawaran paket wisata lainnya di sini silahkan baca selengkapnya .
Apakah anda membutuhkan bantuan untuk mendapatkan gems, atau xp atau food di dragon city? Jangan kuatir karena saat ini sudah ada layanan joki dragon city yang akan membantu anda mendapatkan semuanya itu. Jual Dragon City Food . lihat penawaran lainnya klik di sini .
Untuk melakukan kegiatan outbound yang berkelas anda perlu menyewa jasa pelatihan outbound yang profesional. Hal ini sangat penting untuk menjamin keselamatan para peserta outbound. Ada beberapa layanan outbound yang tersedia saat ini. paket outbound bogor . butuh paket outbound yang lengkap? kunjungi blog .
Jika anda berusaha mengadakan bisnis konveksi baju seragam kantor, maka kami menyediakan jasa konveksi dengan harga murah dan kualitas jahitan yang sangat rapi. Jika anda tertarik, silahkan melihat koleksi dari baju kerja kantor yang kami miliki. Tas seminar Jakarta . Silahkan cek koleksi model tas kami lihat artikel .
Jerawat adalah salah satu masalah yang kerap kali membuat wanita kehilangan rasa percaya diri. Oleh karena itu saya mau memperkenalkan bps yaitu sebuah krim perawatan kecantikan yang bisa membantu anda menghilangkan jerawat yang membandel Jual Online BPS . baca informasi selengkapnya produk majakani ini baca artikel .

Dapatkan beragam info kesehatan di sini. Karena anda akan membutuhkan banyak informasi obat dan sakit penyakit. Semua informasi ini bisa membantu anda untuk hidup lebih sehat dan lebih bahagia. Kunjungi website kami. download di sini . baca selengkapnya cara memutihkan kulit dengan benar cara aman untuk memutihkan kulit .
Apakah anda membutuhkan canopy di rumah anda? Jika anda membutuhkan pemasangan canopy, maka anda bisa menghubungi jasa canopy awning. Dengan canopy ini anda bisa membuat penampilan rumah anda lebih indah. baca di sini . lihat ragam produk canopy kami di sini jenis-jenis canopy awning untuk rumah anda .
Jika anda ingin langsing dengan cara yang sehat, maka kami mempunyai produk hebal yang bisa membantu anda. Produk herbal slim ini dapat menurunkan berat badan yang berlebih. lihat artikel . kenali manfaat dan produk herbal slim. cara kerja dari produk pelangsing herbal slim .
Jika anda adalah tekno mania dan membutuhkan informasi teknologi terbaru, maka kami menyediakan banyak informasi di sini mulai dari gadget tablet, komputer dan lain sebagainya. Dapatkan info seputar teknologi hanya di sini. baca artikel . beli online samsung galaxy dengan harga murah dari toko ini. perbedaan samsung galaxy .
Otomotif adalah dunia yang cukup prestise. Jadi jika anda membutuhkan informasi seputar mobil atau kendaraan terbaru, baik itu harga maupun spesifikasi silahkan hubungi kami. Kami akan membantu anda mendapatkan kendaraan yang anda inginkan.... lihat penjelasan lengkapnya . dapatkan info otomotif selengkapnya di sini mobil toyota avanza .
crystal x adalah produk yang bisa membantu merawat dan menjauhkan wanita dari masalah kewanitaan. Sekarang crystal x semakin populer dan semakin banyak orang yang mencari produk yang satu ini. Jika anda membutuhkan crystal x, maka anda bisa mencarinya di sini. kunjungi blog . Lihat info lengkap dari produk crystal x kandungan antibiotik dalam crystal-x .
Jual rumah di jogja saat inisedang ramai, karena banyak orang yang menjadikan jogja sebagai destinasi untuk kuliah ataupun bekerja. Ini dengan sendirinya mendorong ke arah bisnis jual beli properti seperti rumah, tanah, dan lain sebagainya. lihat artikel . temukan lokasi-lokasi tanah dan rumah di jogya yang sedang dijual kenapa investasi properti semakin menggiurkan .
Hamil dan mendapatkan keturunan adalah sesuatu yang didambakan banyak rumah tangga. Walaupun sudah diyakini anak adalah karunia dari sang pencipta, akan tetapi manusia wajib berusaha untuksesuatu yang diinginkannya. Berikut ini adalah beberapa tips agar cepat hamil. baca artikel . tips hamil lainnya silahkan buka halaman web kami. tips cepat hamil yang paling direkomendasikan .
Dapatkan bahan takoyaki dengan harga murah hanya di sini. Anda juga akan mendapatkan resep takoyaki yang bisa anda pakai untuk memulai bisnis tanpa harus membeli royalti waralaba lihat penjelasan lengkapnya . dapatkan panduan takoyaki dan makanan lainnya di sini resep takoyaki praktis dan mudah .
Jika anda membutuhkan baju batik pekalongan, ada banyak tempat yang menyediakan baju batik pekalongan secara grosir. Salah satunya adalah di web jualan busana grosir baju batik pekalongan. read more . Dapatkan informasi tentang jual grosir busana harga murah. Jual grosir baju batik pekalongan .
Bisnis online fashion saat ini semakin banyak menawarkan busana wanita sehingga anda bisa lebih leluasa memilih beraneka ragam model tanpa harus capek keliling di pasar atau di mall. Jika anda membutuhkan busana dengan desain yang unik, maka evafashionstore bisa menjadi pilihan anda. lihat penawaran kami . dapatkan daftar harga produk apapun itu hanya di sini. Informasi daftar harga handphone terbaru .
Saat ini untuk membuat blog anda semakin SEO friendly anda harus memakai template yang SEO friendly juga. Sudah tidak terhitung opsi template SEO friendly yang ada di internet dan anda bisa memilih salah satunya. Jadi silahkan saudara kunjungi di sini read more . pelajari lebih lanjut cara membuat blognya template blog yang SEO friendly dan responsive .
Bisnis online fashion semakin banyak peminatnya. Ada beberapa orang yang bisa mendapatkan uang dengan cara jualan baju, sepatu, dan tas wanita secara online. Salah satunya adalah evafashionstore yang sudah menekuni bisnis ini sejak 2012 lihat penawaran kami . silahkan lihat koleksi baju wanita dan sepatu lainnya jual sepatu wanita dengan model terbaru .

The ticket is worth the performers who are the best in their periods. I remember that my mother only loved one old singer in her life.how can i make my tinnitus go away

I loved to acknowledge you for this fantastic blog! I really enjoying entire petite item of it besides http://ebookreviews.ning.com/pdf/girlfriend-activation-system-review

Much obliged alot for this data. I'll impart this to others likewise.sewing machine reviews

it is not completely globe vent rather very propitious for the humans those who want to do something good in his person.Takasibet

I must personally we understand the time you devote to create the application. sminkborstar

Buy Provigil Online
wow, awesome post, I was wondering if there is a way to enlarge my penis quickly. and found your site by google, learned a lot, now i’m a bit clear. bookmarked and also signed up your rss. keep us updated.

Thanks for sharing this with us. I found it informative and interesting. Looking forward for more updates. visit this site

The plainer the dress, the greater luster does beauty appear.
Ativan Online

Roller Shutters
Hi, just wanted to say I attended this conference last year, and found it by far the best of about 8 conferences that I attended in the field. Full of professional insight based on testing by experts that knew what they were talking about. I would certain

Solar and wildcard searches often create a problem and this has been stressed over and over again that these things must be fixed according to the guidelines. green news

Di dalam tiap perkantoran ada banyak aktifitas yang membutuhkan tunjangan alat tulis kantor yang memadai. Tidak adanya suply yang terjamin bisa membuat anda kesulitan beraktifitas. Jadi jika anda memerlukan alat tulis kantor anda bisa melakukan pemesanan secara online dan mendapatkan harga terbaik dari kami. jual online alat tulis kantor . pesan alat tulis kantor di sini lihat penjelasan lengkapnya .
Laptop adalah peralatan kerja mobile yang bisa memungkinkan anda melakukan aktifitas kerja di mana saja. Namun untuk membawa laptop anda membutuhkan tas laptop demi kemudahan dan keamanan laptop saudara. Jadi coba dapatkan di toko tas laptop online ini. jual tas bonjour . jual tas laptop dengan harga murah read more .
Olahraga adalah aktifitas yang akan menguras keringat saudara, dan oleh karena itu ada baiknya anda menggunakan baju kaos olahraga yang berkualitas. Baju ini bisa membantu anda menyerap keringat selama olahraga . grosir seragam olahraga . pesan grosir kaos olahraga dan cek modelnya lihat penawaran kami .
Untuk membangun sebuah blog yang SEO friendly anda membutuhkan template blog yang juga SEO friendly dan saat ini salah satu kriteria blog yang SEO friendly adalah responsive design karena akan mudah menyesuaikan dengan layar pengguna internet. Template blog SEO friendly yang responsive . pelajari lebih lanjut cara membuat blognya download di sini .
Wanita saat ini mempunyai selera busana yang sangat kompleks dan semakin jenuh untuk mencarinya di mal atau pasar. Dengan adanya kemajuan teknologi, maka semakin banyak orang yang melakukan belanja online untuk sepatu ataupun baju wanita. jual online aksesoris wanita . silahkan lihat koleksi baju wanita dan sepatu lainnya baca di sini .

Forthwith you constitute it simple for me to think further apparatus. roller conveyor

You must know by now, your article goes to the nitty-gritty of the subject. Your clarity leaves me wanting to know more. Just so you know, i will immediately grab your feed to keep up to date with your online blog. Sounding Buy Diazepam
Out thanks is simply my little

I researed valuable information on this point as I am working on a class project. Thank you posting useful information and its now becoming easier to accomplish this task.
best fish oil

In case you want documents related the complete concept likewise you'll have to transform your current Solr declaration. As opposed to seeking "word*" you must search for "word AS WELL AS word*", merely then documents related "word" will certainly generate from the result-set. purple wedding flowers can be a great colour pertaining to wedding party plants. It may are the palest lavender with a vibrant pink with a royal eggplant tone, plus a huge variety of plants can be bought in pink. Through candelabras in order to blossoms in order to blossom ladies, these include many of the lovliest pink wedding party plants.

You may post on the professional credentials for the blog owner. You could express it's outstanding. Your blog experience can springboard your click through.

I discovered so many fascinating entitys interior your blog especially.how can i cure my diabetes type 2

Its full of information I am looking for and I love to post a comment that "The content of your post is awesome" Great work.
hay day cheats

Its a great pleasure reading your post.Its full of information I am looking for and I love to post a comment that "The content of your post is awesome" Great work

Aspiration you realize my small remark granted.Lovely, exact plus to the item.Vipit

This is one of your vanquish announces, indeed famous process here plus manys of one info.www.theofficialwebsite.co

Recognize your process plus celebrate sharing your information. roller conveyor

Contract match that you are one of the triumph bloggers I endless saw.Concedes for posting this educational rumor.Braveran

Thanks for the info. The plants look absolutely beautiful. I am in Asia at the moment and I miss some of my more familiar flowers. selling bitcoins

It was a very good post indeed. I thoroughly enjoyed reading it in my lunch time.
hack-free.com

I agree on this totally. School matters! design stühle

Ketika mencari "Kereta *" Solr akan kembali "pelatih", "Pelatihan", "melatih" tapi itu tidak akan kembali hasil dengan kata "melatih" di dalamnya. Aku gald untuk menemukan artikel ini. Hai!, saya sangat suka sangat banyak tulisan Anda! berbagi kami cara cepat punya anak , tips supaya cepat hamil

Your difference involving VMware along with Virtuozzo Canisters is over just your name. Only hosting companies using VMware may offer complete freedom, security along with capacity, and also options pertaining to high access, load evening out and problem recovery. virtual server

In Aurora, there are your excellent pool table for virtually any basement or lounge room. We offer lots of different pool tables through the finest labels in pool, including National Heritage and Cannon. billiards

This is a great article thanks for sharing this informative information. HD mxf files conversion software mxf converter | pdf conversion to Office pdf to word

Learn what steps to take in order to save money during a recession. Are there ways of saving money during a recession? Recession is a word that has a negative meaning for many people; it fills many people full of a dreadful fear of loss. People are scared that it means www.financialaidaudit.com

Massage Tucson
Innovation has nothing to do with how many R amp&; D dollars you have. When Apple came up with the Mac, IBM was spending at least 100 times more on R & D. It's not about money. It's about the people you have, how you're led, and how much you get it.

In case you want documents matching the exact word as well you will have to change your Solr statement. Instead of searching for "word*" you'll have to look for "word OR word*", only then documents matching "word" will turn up in the result-set.

Most Popular Websites

Your article has piqued a lot of positive interest. I can see why since you have done such a good job of making it interesting.
how to unlock iphone 4 when disabled

It is good to see the consumer sales of furniture up in the United States, but it is also unfortunate because all of this furniture isn't made in the US anymore. All we're doing is adding to the deforestation of Southeast Asia and the trade deficits here the United States. No, we don't live in a perfect world, www.furnituresaleillinois.com

Find Inspiring Quotes On Facebook. It's Quick, Easy & Free. Join Now!
arabchat

I definitely enjoying every little bit of it. It is a great website and nice share. Jual Mobil Hotwheels

One secret of success in life is for a man to be ready for his opportunity when it comes.
Peter J. Burns III

Flaming enthusiasm, backed up by horse sense and persistence, is the quality that most frequently makes for success.
amber teething necklace

Success is getting what you want. Happiness is wanting what you get.
mobilieji telefonai

Great job for publishing such a beneficial web site. Your web log isn’t only useful but it is additionally really creative too. There tend to be not many people who can certainly write not so simple posts that artistically. Continue the nice writing
double stroller reviews

Enhance prominence growth formula not basically has been discovered to build the tallness for some people over the globe. They have additionally shown up for have extended their trust as well.

Pages