Re: [sqlalchemy] String matching

2012-02-07 Thread Michael Bayer
On Feb 7, 2012, at 12:34 PM, yannack wrote: > Hello list, > I have the following problem. I wish to query my database to look for > columns with names included in, or including, a given string. > is there a way to do the opposite of "contains", ie, a "contained" > method for string columns? Right

RE: [sqlalchemy] String matching

2012-02-07 Thread Jackson, Cameron
@googlegroups.com Subject: RE: [sqlalchemy] String matching I'm not sure how to do exactly what you're asking, but I have an alternative suggestion: You could just query everything and do the filter at the application level (i.e. in Python), rather than in the query. Because Python

RE: [sqlalchemy] String matching

2012-02-07 Thread Jackson, Cameron
knowing your situation. If in doubt, try both and profile. Cheers, Cam -Original Message- From: sqlalchemy@googlegroups.com [mailto:sqlalchemy@googlegroups.com] On Behalf Of yannack Sent: Wednesday, 8 February 2012 4:35 AM To: sqlalchemy Subject: [sqlalchemy] String matching Hello list,

[sqlalchemy] String matching

2012-02-07 Thread yannack
Hello list, I have the following problem. I wish to query my database to look for columns with names included in, or including, a given string. is there a way to do the opposite of "contains", ie, a "contained" method for string columns? Right now, I am doing the following: session.query(Parcours)