try to add double quotes around your search_var
In standard sql syntax, keywords should put in quotes(?I'm not
sure,but without quotes they won't work)
=============================================
db.select('books', where='title LIKE "$search_var"', vars=locals())
==============================================
On Jan 20, 5:46 am, geekbuntu <[email protected]> wrote:
> does anyone have a good sql statement for webpy to query results by
> "LIKE" (e.g. results = db.select('books', where='title LIKE
> $search_var', vars=locals()) )? (this suggestion was from Justin but
> doesn't work)
>
> i just found something on github/webpy repository
> it offered another way to do the 'like' - it didn't work
> eitherhttp://github.com/webpy/webpy/issues/issue/2
>
> logically this shouldn't be much of an issue... it's just a mysql
> statement like any other really
>
> hope someone knows of a way to do this.
>
> tia,
> greg
--
You received this message because you are subscribed to the Google Groups
"web.py" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/webpy?hl=en.