Add REGEXP support to SQL queries
|Reported by:||Owned by:|
|Severity:||minor||Keywords:||sqlite regexp patch|
SQLite allows the use of a REGEXP search . Such a feature would be useful in cases such as parsing multiple CCs, multiple asignees on a ticket , etc. All that has to be done is to create a user function on the connection .
I've attached a diff of what (I think) will enable this (I am using r3406 currently). The patch will add a user function in SQLite immediately after the connection is made. The user function is called regexp. (See trac_sqlite_regexp_r3406.patch)
- http://www.sqlite.org/lang_expr.html: What is currently allowed in SQLite expressions
- #2662: Using REGEXP in SQLite to parse multi-user assignments
- http://initd.org/pub/software/pysqlite/doc/usage-guide.html#creating-user-defined-functions pysqlite documentation to add a user-defined function