aboutsummaryrefslogtreecommitdiff
path: root/odb/database.hxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2013-09-02 08:33:25 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2013-09-02 08:33:25 +0200
commit7fb59e3beca03493426d0b4c4153d7e6b6d2f34b (patch)
tree8e40e361dbd5f7c0dd9491e3c932887048760d21 /odb/database.hxx
parent0770beace3b6f944209417f1b4541fa31d443529 (diff)
Support for versioning simple value in object
Diffstat (limited to 'odb/database.hxx')
-rw-r--r--odb/database.hxx8
1 files changed, 8 insertions, 0 deletions
diff --git a/odb/database.hxx b/odb/database.hxx
index ea5a37a..c7c4598 100644
--- a/odb/database.hxx
+++ b/odb/database.hxx
@@ -370,6 +370,13 @@ namespace odb
schema_version_table (const std::string& table_name,
const std::string& schema_name);
+ // Schema version sequence number. It is incremented every time
+ // the schema version or migration flag is changed and can be
+ // used to detect version changes. The starting value is 1.
+ //
+ unsigned int
+ schema_version_sequence () const;
+
protected:
struct schema_version_info: schema_version_migration_type
{
@@ -471,6 +478,7 @@ namespace odb
std::string schema_version_table_;
mutable schema_version_map schema_version_map_;
+ unsigned int schema_version_seq_;
};
}