Sample Header Ad - 728x90

How to query efficiently from Postgres to select special words?

3 votes
3 answers
3648 views
Let's say that I have a table called words with very many records. Columns are id and name. In the words table I have for example: 'systematic', 'سلام','gear','synthesis','mysterious', etc. **NB: we have utf8 words, too.** How to query efficiently to see which words include letters 's', 'm' and 'e' (all of them)? The output would be: systematic,mysterious I have no idea how to do such a thing. It should be efficient because our server would suffer otherwise.
Asked by Alireza (3676 rep)
Dec 17, 2013, 08:55 AM
Last activity: Feb 19, 2024, 09:45 PM