aboutsummaryrefslogtreecommitdiff
path: root/qt/mssql/date-time/driver.cxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2012-01-18 14:34:06 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2012-01-20 15:45:47 +0200
commit092163ffe44f64387508a0770948636f79ae139d (patch)
tree1f4817af1d2462424ff4e4f9d7b76f8f59fb3d7b /qt/mssql/date-time/driver.cxx
parent605e4dee303f2a7b3b493e7a73faa09e61d88839 (diff)
Add support for configuring test suite with additional macros
Diffstat (limited to 'qt/mssql/date-time/driver.cxx')
-rw-r--r--qt/mssql/date-time/driver.cxx4
1 files changed, 4 insertions, 0 deletions
diff --git a/qt/mssql/date-time/driver.cxx b/qt/mssql/date-time/driver.cxx
index 66d6b67..0e7681a 100644
--- a/qt/mssql/date-time/driver.cxx
+++ b/qt/mssql/date-time/driver.cxx
@@ -53,10 +53,12 @@ main (int argc, char* argv[])
// Check persistence of valid dates and times.
//
+#if !defined(MSSQL_SERVER_VERSION) || MSSQL_SERVER_VERSION >= 1000
QDateTime t (QDateTime::currentDateTime ());
o.date = t.date ();
o.date_time = t;
+#endif
// In DATETIME fractional seconds are rounded to .000, .003, or .007.
//
@@ -68,7 +70,9 @@ main (int argc, char* argv[])
o.date_time_sdt = QDateTime (QDate (2012, 1, 14),
QTime (11, 57, 0, 0));
+#if !defined(MSSQL_SERVER_VERSION) || MSSQL_SERVER_VERSION >= 1000
o.time = t.time ();
+#endif
{
transaction t (db->begin ());