Author: wyoung
Date: Thu Oct 25 15:11:28 2007
New Revision: 1786
URL: http://svn.gna.org/viewcvs/mysqlpp?rev=1786&view=rev
Log:
Added Query::errnum(), which just wraps Connection::errnum(); we already
have Query::error() wrapping Connection::error(), so it's appropriate.
Patch suggested by Jim Wallace.
Modified:
trunk/lib/query.h
Modified: trunk/lib/query.h
URL:
http://svn.gna.org/viewcvs/mysqlpp/trunk/lib/query.h?rev=1786&r1=1785&r2=1786&view=diff
==============================================================================
--- trunk/lib/query.h (original)
+++ trunk/lib/query.h Thu Oct 25 15:11:28 2007
@@ -174,6 +174,12 @@
/// \brief Return true if the object has experienced an error
bool operator !() { return !copacetic_; }
+ /// \brief Get the last error number that was set.
+ ///
+ /// This just delegates to Connection::errnum(). Query has nothing
+ /// extra to say, so use either, as makes sense in your program.
+ int errnum() const { return conn_->errnum(); }
+
/// \brief Get the last error message that was set.
///
/// This just delegates to Connection::error(). Query has nothing
_______________________________________________
Mysqlpp-commits mailing list
[email protected]
https://mail.gna.org/listinfo/mysqlpp-commits