Regexp i switch stops working suddenly

diggy
Wed, 15 Apr 2020 16:43:15 +0000
Dgraph

Moved from GitHub dgraph/5214

Posted by nadeemnazeer3:

I Have a trigram index on one of my predicates to allow me do case insensitive match using regexp. But issue is when i do
regexp(TITLE, /Some Term/i)
It won’t return any results ?
If i do without “i” like this It does return results!?
regexp(TITLE, /Some Term/)
Initially i faced this when i was testing via setting up dgraph via docker; but now it got even triggered suddenly on server as well after I loaded some more data.
e.g:

{
  term(func:  regexp(TITLE, /Nadeem N/i)) {
   name: TITLE
   tag
    }
}

It won’t return me anything ; only after i remove /i it does
with schema

<TITLE>: string @index(exact, trigram) .

Dgraph version : v1.2.1
Dgraph SHA-256 : 3f18ff84570b2944f4d75f6f508d55d902715c7ca2310799cc2991064eb046f8
Commit SHA-1 : ddcda9296
Commit timestamp : 2020-02-06 15:31:05 -0800
Branch : HEAD
Go version : go1.13.5

3 posts - 1 participant