aboutsummaryrefslogtreecommitdiff
path: root/qt/mssql/template/driver.cxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2012-01-14 09:43:38 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2012-01-20 15:45:46 +0200
commit0da5345276f1e655e5e099fdf6280466e3a5dda4 (patch)
tree51c61e4dfef993aa4a7d6b6e9735324e118c18a3 /qt/mssql/template/driver.cxx
parente0849593316ba0f3e45545dad98ee9218d017184 (diff)
Date-time part of Qt profile implementation for SQL Server
Diffstat (limited to 'qt/mssql/template/driver.cxx')
-rw-r--r--qt/mssql/template/driver.cxx48
1 files changed, 48 insertions, 0 deletions
diff --git a/qt/mssql/template/driver.cxx b/qt/mssql/template/driver.cxx
new file mode 100644
index 0000000..070ed91
--- /dev/null
+++ b/qt/mssql/template/driver.cxx
@@ -0,0 +1,48 @@
+// file : qt/mssql/template/driver.cxx
+// author : Constantin Michael <constantin@codesynthesis.com>
+// copyright : Copyright (c) 2009-2011 Code Synthesis Tools CC
+// license : GNU GPL v2; see accompanying LICENSE file
+
+// PLACE TEST DESCRIPTION HERE
+//
+
+#include <memory> // std::auto_ptr
+#include <cassert>
+#include <iostream>
+
+#include <QtCore/QCoreApplication>
+
+#include <odb/mssql/database.hxx>
+#include <odb/mssql/transaction.hxx>
+
+#include <common/common.hxx>
+
+#include "test.hxx"
+#include "test-odb.hxx"
+
+using namespace std;
+using namespace odb::core;
+
+int
+main (int argc, char* argv[])
+{
+ QCoreApplication app (argc, argv);
+
+ try
+ {
+ auto_ptr<database> db (create_database (argc, argv));
+
+ //
+ //
+ cout << "test 001" << endl;
+ {
+ transaction t (db->begin ());
+ t.commit ();
+ }
+ }
+ catch (const odb::exception& e)
+ {
+ cerr << e.what () << endl;
+ return 1;
+ }
+}