From cd44a367fd73293b1c8edc36aa61667ca020a2eb Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Mon, 5 Mar 2012 11:59:00 +0200 Subject: Add support for generating schema creation code into separate C++ file --- doc/manual.xhtml | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'doc/manual.xhtml') diff --git a/doc/manual.xhtml b/doc/manual.xhtml index 347c8ef..5060268 100644 --- a/doc/manual.xhtml +++ b/doc/manual.xhtml @@ -2394,16 +2394,16 @@ auto_ptr<odb::database> db (

There are several ways to create the database schema. The easiest is to instruct the ODB compiler to generate the corresponding schema from the persistent classes (--generate-schema option). The ODB - compiler can generate the schema either as a standalone SQL file or - embedded into the generated C++ code (--schema-format - option). If we are using the SQL file to create the database schema, then - this file should be executed, normally only once, before the application - is started.

- -

Alternatively, the schema can be embedded directly into the generated - code and we can use the odb::schema_catalog class to - create it in the database from within our application, - for example:

+ compiler can generate the schema as a standalone SQL file, + embedded into the generated C++ code, or as a separate C++ source file + (--schema-format option). If we are using the SQL file + to create the database schema, then this file should be executed, + normally only once, before the application is started.

+ +

Alternatively, if the schema is embedded directly into the generated + code or produced as a separate C++ source file, then we can use the + odb::schema_catalog class to create it in the database + from within our application, for example:

 #include <odb/schema-catalog.hxx>
-- 
cgit v1.1