|
Boost : |
Subject: Re: [boost] Boost.SQL?
From: Daniel Pfeifer (daniel_at_[hidden])
Date: 2010-09-15 06:31:21
A while back, I did some experiments with prepared statements and
boost::function (see http://github.com/purpleKarrot/async-db).
Have a look at the mysql example. As I recall, it did work.
http://github.com/purpleKarrot/async-db/blob/master/examples/mysql.cpp
I currently lack the time to work further on this, but if you
concentrate on string generation (which I did not), there might be some
interesting combinations.
Something like this would be cool:
. function<void(int, string, gregorian::date)> insert
. = sql::bind(INSERT > INTO > users(id, name, registered),
. VALUES(int_, string_, date_));
. insert(1003, "Bob", gregorian::day_clock::local_day());
cheers, Daniel
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk