aboutsummaryrefslogtreecommitdiff
path: root/common/query
diff options
context:
space:
mode:
Diffstat (limited to 'common/query')
-rw-r--r--common/query/driver.cxx22
1 files changed, 9 insertions, 13 deletions
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<person> r (db->query<person> (q));
- print (r);
- }
-
- {
- name = "Dirt";
- age = 31;
- result<person> r (db->query<person> (q));
- print (r);
- }
+ name = "Doe";
+ age = 30;
+ result<person> r (db->query<person> (q));
+ print (r);
+
+ name = "Dirt";
+ age = 31;
+ r = db->query<person> (q);
+ print (r);
t.commit ();
}