Search code examples
javascripttaffydb

Non-case sensitive query with TaffyDB (or other JS DB)


I'm using TaffyDB for a "DB" for the website I am working on right now. Its pretty neat, I can do 'like' searches. However, the 'like' search is still case sensitive and that if a record exist: "Banana", a query of "banana" will fail.

  • Anyone knows how to use TaffyDB for such query
  • Or, is there a JS DB that can do such function

Solution

  • Simply use likenocase:

    db( {title:{"likenocase":val}} ).order( ...