aboutsummaryrefslogtreecommitdiff
path: root/odb/options.cli
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2013-04-03 11:22:42 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2013-04-10 18:46:44 +0200
commitb0391e168b489811708ca7ba5f71a0eb67b46ffe (patch)
treece15fb5ce0998ec27696152054609bb5dd4f45c3 /odb/options.cli
parente356a9112750e836197a8545bcf6cedad0c1ebe1 (diff)
Generate add/drop table migration statements
Diffstat (limited to 'odb/options.cli')
-rw-r--r--odb/options.cli47
1 files changed, 46 insertions, 1 deletions
diff --git a/odb/options.cli b/odb/options.cli
index b086011..457c06f 100644
--- a/odb/options.cli
+++ b/odb/options.cli
@@ -112,7 +112,14 @@ class options
the generated C++ code. By default the SQL file is generated for
the MySQL, PostgreSQL, Oracle, and Microsoft SQL Server databases
and the schema is embedded into the C++ code for the SQLite database.
- Use the \cb{--schema-format} option to alter the default schema format."
+ Use the \cb{--schema-format} option to alter the default schema format.
+
+ If database schema evolution support is enabled (that is, the object
+ model version is specified), then this option also triggers the
+ generation of database schema migration statements, again either as
+ standalong SQL files or embedded into the generated C++ code. You can
+ suppress the generation of schema migration statements by specifying
+ the \cb{--suppress-migration} option."
};
bool --generate-schema-only
@@ -122,6 +129,11 @@ class options
for details)."
};
+ bool --suppress-migration
+ {
+ "Suppress the generation of database schema migration statements."
+ };
+
database_map<std::set< ::schema_format> > --schema-format
{
"<format>",
@@ -323,6 +335,13 @@ class options
options unless they are absolute paths."
};
+ bool --init-changelog
+ {
+ "Force re-initialization of the changelog even if one exists (all the
+ existing change history will be lost). This option is primarily useful
+ for automated testing."
+ };
+
database_map<std::string> --odb-file-suffix
{
"<suffix>",
@@ -428,6 +447,12 @@ class options
"Insert <text> at the beginning of the generated database schema file."
};
+ database_map<std::vector<std::string> > --migration-prologue
+ {
+ "<text>",
+ "Insert <text> at the beginning of the generated database migration file."
+ };
+
// Interludes.
//
database_map<std::vector<std::string> > --sql-interlude
@@ -469,6 +494,12 @@ class options
"Insert <text> at the end of the generated database schema file."
};
+ database_map<std::vector<std::string> > --migration-epilogue
+ {
+ "<text>",
+ "Insert <text> at the end of the generated database migration file."
+ };
+
// Prologue files.
//
database_map<std::string> --hxx-prologue-file
@@ -506,6 +537,13 @@ class options
database schema file."
};
+ database_map<std::string> --migration-prologue-file
+ {
+ "<f>",
+ "Insert the content of file <f> at the beginning of the generated database
+ migration file."
+ };
+
// Interlude files.
//
database_map<std::string> --sql-interlude-file
@@ -552,6 +590,13 @@ class options
schema file."
};
+ database_map<std::string> --migration-epilogue-file
+ {
+ "<f>",
+ "Insert the content of file <f> at the end of the generated database
+ migration file."
+ };
+
// ODB compilation prologue/epilogue.
//
database_map<std::vector<std::string> > --odb-prologue