With SQLite Encryption Extension (SEE) or other similar encryptions, how the operator "LIKE" will work efficiently?

Viewed 194

Suppose a database stores user chats. Often, it's required to search the content by partial words of the sentence.

E.g. "Hello world" and "JP Morgan" both should be found when user searches "or".
For such queries, we use keyword LIKE with wildcard % operator.

Now if we use SEE or any other encryptions, how will such a scenario work?

  • Will it load the whole DB in cache? (RAM intensive)
  • Will it decrypt every item first and then compare each item with the wildcard? (CPU intensive)

What is the correct way to solve such a problem without using too much on memory or CPU?

0 Answers
Related