Hi,

vrs762 wrote:
> In sql syntax one can do select * from table where attribute like
> '%value%'
>
> However, how would one do that using the sqlalchemy's get/get_by
> methods?
>
> I tried different combinations but got only syntax errors.
>   
Just starting with SA, but what about something along these lines:

session.query(User).filter(User.name.like('%ed'))

or

session.query(User).filter_by(name='ed', fullname='Ed Jones')

Werner


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"TurboGears" 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/turbogears?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to