[Sqlalchemy-tickets] Issue #3059: Tutorial should note that MATCH doesn't work out-of-the-box in SQ
Brought to you by:
zzzeek
|
From: Tom X. T. <iss...@bi...> - 2014-05-23 22:57:21
|
New issue 3059: Tutorial should note that MATCH doesn't work out-of-the-box in SQLite https://bitbucket.org/zzzeek/sqlalchemy/issue/3059/tutorial-should-note-that-match-doesnt Tom X. Tobin: The following example in the tutorial doesn't work when using SQLite as instructed, raising an `OperationalError`: ``` # The tutorial doesn't make this explicit: # query = session.query(User) query.filter(User.name.match('wendy')) ``` The tutorial should note that `MATCH` (like `REGEXP`) [doesn't work out-of-the-box in SQLite] [1]: > The MATCH operator is a special syntax for the match() application-defined function. The default match() function implementation raises an exception and is not really useful for anything. But extensions can override the match() function with more helpful logic. [1]: http://www.sqlite.org/lang_expr.html |