How to turn on REGEXP in SQLite3 and Rails 3.1?

后端 未结 6 1924
谎友^
谎友^ 2020-12-11 16:28

I have the following statement in Rails 3 using an SQLite3 database:

word = \'Hello\'
word_entry = Word.where(\"name REGEXP :word\", {:word => \"[[:<:]         


        
6条回答
  •  情深已故
    2020-12-11 16:55

    You may be intested in the sqlite3-pcre package, which implements REGEXP for SQLite.

    See this comment on a similar issue.

提交回复
热议问题