Author: wyoung
Date: Tue May 18 22:08:17 2010
New Revision: 2654

URL: http://svn.gna.org/viewcvs/mysqlpp?rev=2654&view=rev
Log:
Added global NOW() function, returning a DateTime initted to yield SQL
NOW() call.  We already had DateTime::now(), but this is shorter and
matches the SQL syntax.

Modified:
    trunk/Wishlist
    trunk/lib/datetime.h

Modified: trunk/Wishlist
URL: 
http://svn.gna.org/viewcvs/mysqlpp/trunk/Wishlist?rev=2654&r1=2653&r2=2654&view=diff
==============================================================================
--- trunk/Wishlist (original)
+++ trunk/Wishlist Tue May 18 22:08:17 2010
@@ -23,8 +23,6 @@
       installed first.
 
     o Check that it works with Connector/C and MySQL 5.1
-
-    o Add to datetime.h: inline DateTime NOW() { return DateTime(); }
 
 
 v3.2 Plan: Finish SSQLS v2

Modified: trunk/lib/datetime.h
URL: 
http://svn.gna.org/viewcvs/mysqlpp/trunk/lib/datetime.h?rev=2654&r1=2653&r2=2654&view=diff
==============================================================================
--- trunk/lib/datetime.h (original)
+++ trunk/lib/datetime.h Tue May 18 22:08:17 2010
@@ -201,6 +201,11 @@
 };
 
 
+/// \brief Returns a DateTime object that, when inserted into query
+/// will yield a SQL "NOW()" function call.
+inline DateTime NOW() { return DateTime(); }
+
+
 /// \brief Inserts a DateTime object into a C++ stream in a
 /// SQL-compatible format.
 ///


_______________________________________________
Mysqlpp-commits mailing list
[email protected]
https://mail.gna.org/listinfo/mysqlpp-commits

Reply via email to