[Zope-DB] case insensitive ZSQL queries

garry saddington garry at schoolteachers.co.uk
Thu Sep 6 03:10:30 EDT 2007



On Wed, 2007-09-05 at 16:16 -0700, onsombal wrote:
> is there an easy way to make the following ZSQL query case-insensitive?
> 
> select * from clients
> <dtml-sqlgroup where>
>     <dtml-sqltest firstname op="like" type="string" optional>
>   <dtml-or>
>     <dtml-sqltest lastname op="like" type="string" optional>
>   <dtml-or>
>     <dtml-sqltest client op="like" type="string" optional>
>   </dtml-sqlgroup>
> 
> Thanks... Jim
> 
> 
If you use Postgresql then change the 'like' to 'ilike'.
Regards
Garry



More information about the Zope-DB mailing list