4 ms·
This has been a great thread, and there's some heavyweight indexes here. But what about at the other end of the scale? Say when you've got 10k-50k contact deta
by porker 7y ago
This has been a great thread, and there's some heavyweight indexes here. But what about at the other end of the scale?
Say when you've got 10k-50k contact details (name, email, phone) and you want to provide a quick, autocomplete lookup. I've used basic SQL string matching for this, but it doesn't catch mis-spellings and the rest.
Running SOLR or ES is overkill for this. Is there a tool that fits this niche?
- noir_lord 7y agoPostgres does lexemes and all that jazz natively. You want to be looking for tsvector related stuff. I used it a few years ago to do full text search on a smallish website and it was great, I gather it has improved further since.
- mohaine 7y agoLucene should work great for this use case. It has been awhile but I have successfully used it for this exact use case.
- softwaredoug 7y agoThis is a great niche for Algolia, instant fuzzy 'autocomplete' style search of short strings
- samsk 7y agoWith Postgresql you can use pg_trgm, might be not as powerful as what SOLR/ES provides, but easier to run.
- peterdm 7y agoUpvoted. This is how Postgres supports "fuzzy searching" which helps with misspellings. https://www.rdegges.com/2013/easy-fuzzy-text-searching-with-postgresql/ https://www.rdegges.com/2013/easy-fuzzy-text-searching-with-... Completion response-time will be slower than Solr, Elasticsearch, Algolia, etc... but if you're already running Postgres, this may be the fastest to deliver for you.
- rpedela 7y agoWhat's wrong with running Solr/ES? It is trivial to run either in standalone mode, and it is a lot easier to set up autocomplete with misspelling support than messing with PG. Algolia is a good option if you have the budget.
- porker 7y ago> What's wrong with running Solr/ES? With this small quantity of data, usually the app's running on a small VM. I'm wary of running anything Java, having had it require large amounts of RAM before. That said, I haven't touched JVM stuff for 5+ years.
- karterk 7y agoYes! Please take a look at an open source search engine I am working on. You will definitely like it: https://github.com/typesense/typesense https://github.com/typesense/typesense Would love to hear your feedback :)