[Zope-DB] Please help me about driver adapter
JPenny at ykksnap-america.com
JPenny at ykksnap-america.com
Fri Feb 16 10:40:01 EST 2007
An alternative is:
select * from students
where surname like '%<dtml-var surname sql_quote>%'
This is a bit more succinct, but if you use it, be sure not to
forget the sql_quote, or you will be open to sql injection problems.
jim penny
zope-db-bounces at zope.org wrote on 02/16/2007 02:57:37 AM:
> On Fri, 2007-02-16 at 07:38 +0100, robert rottermann wrote:
> > I do not think any one of us can help you unless you tell us what
> > exactly your problem with installing pymssql ist.
> > by the way: do you mean MySQLdb?
> >
> > there is very good documentation on using Z SQL in the zope book:
> > http://www.plope.com/Books/2_7Edition/RelationalDatabases.stx
> >
> > there you find examples how to use a query with like.
> > robert
> Here's an example of how to use like and wildcards in sqlvar's
>
> select * from students
> where surname ilike <dtml-sqlvar expr="'%'+surname+'%'" type="string">
>
> Regards
> Garry
>
> _______________________________________________
> Zope-DB mailing list
> Zope-DB at zope.org
> http://mail.zope.org/mailman/listinfo/zope-db
More information about the Zope-DB
mailing list