3 ms·
Has anyone done a serious implementation on top of full-text search functionality in Postgres? I have a pretty large dataset that's currently in Postgres and I'
by avenoir 9y ago
Has anyone done a serious implementation on top of full-text search functionality in Postgres? I have a pretty large dataset that's currently in Postgres and I'm deciding between it and Elasticsearch.
- rpedela 9y agoDepends on your needs, but ES is a superior search engine in just about every way. PG may be good enough for your needs though. In my general view, if you want a more powerful and easy-to-use alternative to LIKE then PG search is great. If you need something more like Google then you should use ES.
- jeltz 9y agoNot just that. PostgreSQL also offers a clear advantage if you need to access both full text data and relational or geographical data in the same query. On the other hand what you say is true, ES is much more flexible in what it can offer in full text search.
- rpedela 9y agoES is very good at storing and querying non-text data including geo data although there are exceptions such as numeric. Both PG and ES have their strengths and weaknesses. ES is great at search. PG is great at joins and constraints. Everything else depends a lot on the specific use case.
- jeltz 9y agoYes, both databases can handle all kinds of data and have support for a wide range of index types, but ES does not come anywhere close to PostGIS when it comes to geodata. PG is superior at search for geodata, while ES is superior at text search.
- elchief 9y agoPG 9.6 has phrase search now which is nice. And multi-word synonyms beats most search servers. Lack of BM25 or TFIDF (see the `smlar` extension) is the main issue