Author: wyoung
Date: Thu Oct 25 14:49:03 2007
New Revision: 1784
URL: http://svn.gna.org/viewcvs/mysqlpp?rev=1784&view=rev
Log:
- Added UseQueryError exception type
- Using it instead of BadQuery in one instance, since a change we're
about to make to it will make BadQuery inappropriate.
Patch by Jim Wallace.
Modified:
trunk/lib/exceptions.h
trunk/lib/result.h
Modified: trunk/lib/exceptions.h
URL:
http://svn.gna.org/viewcvs/mysqlpp/trunk/lib/exceptions.h?rev=1784&r1=1783&r2=1784&view=diff
==============================================================================
--- trunk/lib/exceptions.h (original)
+++ trunk/lib/exceptions.h Thu Oct 25 14:49:03 2007
@@ -234,6 +234,19 @@
~BadParamCount() throw() { }
};
+/// \brief Exception thrown when something goes wrong in processing a
+/// "use" query.
+
+class MYSQLPP_EXPORT UseQueryError : public Exception
+{
+public:
+ /// \brief Create exception object
+ explicit UseQueryError(const char* w = "") :
+ Exception(w)
+ {
+ }
+};
+
/// \brief Exception thrown when MySQL encounters a problem while
/// processing your query.
Modified: trunk/lib/result.h
URL:
http://svn.gna.org/viewcvs/mysqlpp/trunk/lib/result.h?rev=1784&r1=1783&r2=1784&view=diff
==============================================================================
--- trunk/lib/result.h (original)
+++ trunk/lib/result.h Thu Oct 25 14:49:03 2007
@@ -105,7 +105,7 @@
{
if (!result_) {
if (throw_exceptions()) {
- throw BadQuery("Results not fetched");
+ throw UseQueryError("Results not fetched");
}
else {
return Row();
_______________________________________________
Mysqlpp-commits mailing list
[email protected]
https://mail.gna.org/listinfo/mysqlpp-commits