aboutsummaryrefslogtreecommitdiff
path: root/common/erase-query/test.hxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2011-08-25 11:02:20 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2011-08-25 11:02:20 +0200
commit18dc4c5a4cb46f01ebdd49fbb6baa3c48d8f3b3d (patch)
tree600125a04797d7261e748507c4c3d8eea5eadbf2 /common/erase-query/test.hxx
parentff3950866c0f756a5b6f379b9f95f01fff4a9ec7 (diff)
Add experimental code (commented out) for DELETE JOIN support
This would be needed to support object relationships in the erase_query() functionality.
Diffstat (limited to 'common/erase-query/test.hxx')
-rw-r--r--common/erase-query/test.hxx19
1 files changed, 18 insertions, 1 deletions
diff --git a/common/erase-query/test.hxx b/common/erase-query/test.hxx
index be5539f..781eedd 100644
--- a/common/erase-query/test.hxx
+++ b/common/erase-query/test.hxx
@@ -10,15 +10,18 @@
#include <odb/core.hxx>
+struct object2;
+
#pragma db object
struct object
{
object (unsigned long id)
- : id_ (id)
+ : id_ (id), o1 (0), o2 (0)
{
}
object ()
+ : o1 (0), o2 (0)
{
}
@@ -26,6 +29,20 @@ struct object
unsigned long id_;
std::vector<int> v;
+
+ int num;
+
+ object* o1;
+ object2* o2;
+};
+
+#pragma db object
+struct object2
+{
+ #pragma db id auto
+ unsigned long id_;
+
+ int num;
};
#endif // TEST_HXX