On Tue, Jan 4, 2011 at 2:15 AM, Nikolai Weh <[email protected]> wrote:
> Hello,
>
> if i use the session::reconnect() method to connect to a MySQL server
> after a timeout, will my prepared statements still be functional
> (including previously inserted parameters), or do i have to
> re-initialize them again?

Hello Nikolai,

In the MySQL backend, preparing a statement means just building some
in-memory data structures, so yes the statements should survive
session::reconnect().  I just added a small test to test-mysql.cpp
which verifies this:
http://soci.git.sourceforge.net/git/gitweb.cgi?p=soci/soci;a=commitdiff;h=723e033a1481209487b8e567d6a007030a62ce37

Thanks,

Aleksander

------------------------------------------------------------------------------
Gaining the trust of online customers is vital for the success of any company
that requires sensitive data to be transmitted over the Web.   Learn how to 
best implement a security strategy that keeps consumers' information secure 
and instills the confidence they need to proceed with transactions.
http://p.sf.net/sfu/oracle-sfdevnl 
_______________________________________________
Soci-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/soci-users

Reply via email to