From 959f49cdeb02c1be24a535befde7b02de78a7fbd Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Thu, 23 Sep 2010 09:08:42 +0200 Subject: Use comparison instead of IS TRUE The bool type can be mapped to a non-integral type, such as string. --- odb/mysql/query.txx | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/odb/mysql/query.txx b/odb/mysql/query.txx index 5063082..deafad0 100644 --- a/odb/mysql/query.txx +++ b/odb/mysql/query.txx @@ -15,7 +15,11 @@ namespace odb query (const query_column& c) : clause_ (c.name ()) { - clause_ += " IS TRUE"; + // Cannot use IS TRUE here since database type can be a non- + // integral type. + // + clause_ += " = "; + append (val_bind (true)); } // query_column -- cgit v1.1