Discussion:
[soci-users] Streams in SOCI
Nicolas Deroche
2013-06-04 16:07:39 UTC
Permalink
Hello,
I have a simple IpAddress class, basically a std::string container.
I would like to make it streamable using SOCI, ie

soci::statement st =
(sql.prepare << "SELECT lastlogin_ip FROM `accounts` WHERE `id`=':ii'",
soci::into(account->lastlogin_ip),
soci::use(id, "ii"));
st.execute();

And same for soci::use(ip, "the_ip_ind");
How can I do it ?
Thanks, nico.
Mateusz Loskot
2013-06-04 17:17:51 UTC
Permalink
Check the ORM example at
http://soci.sf.net/doc/3.2/exchange.html#object_relational
--
Mateusz Loskot
(Sent from mobile, apology for top-posting and broken quotes)
Post by Nicolas Deroche
Hello,
I have a simple IpAddress class, basically a std::string container.
I would like to make it streamable using SOCI, ie
soci::statement st =
(sql.prepare << "SELECT lastlogin_ip FROM `accounts` WHERE `id`=':ii'",
soci::into(account->lastlogin_ip),
soci::use(id, "ii"));
st.execute();
And same for soci::use(ip, "the_ip_ind");
How can I do it ?
Thanks, nico.
------------------------------------------------------------------------------
1. A cloud service to automate IT design, transition and operations
2. Dashboards that offer high-level views of enterprise services
3. A single system of record for all IT processes
http://p.sf.net/sfu/servicenow-d2d-j
_______________________________________________
soci-users mailing list
https://lists.sourceforge.net/lists/listinfo/soci-users
Loading...