From 9ed005a6000008b8e84d98a52407a0ab8cb412d0 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Tue, 10 Aug 2010 13:59:08 +0200 Subject: Test new result interface --- common/query/driver.cxx | 22 +++++++++------------- 1 file changed, 9 insertions(+), 13 deletions(-) (limited to 'common') diff --git a/common/query/driver.cxx b/common/query/driver.cxx index 214dd7b..bcfbff1 100644 --- a/common/query/driver.cxx +++ b/common/query/driver.cxx @@ -137,19 +137,15 @@ main (int argc, char* argv[]) query q ("age >= " + query::_ref (age) + "AND" + "last_name = " + query::_ref (name)); - { - name = "Doe"; - age = 30; - result r (db->query (q)); - print (r); - } - - { - name = "Dirt"; - age = 31; - result r (db->query (q)); - print (r); - } + name = "Doe"; + age = 30; + result r (db->query (q)); + print (r); + + name = "Dirt"; + age = 31; + r = db->query (q); + print (r); t.commit (); } -- cgit v1.1