From 4fd2c107242fe9f8e6ba7ded2a789f4de2ccd040 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Wed, 26 Oct 2016 16:41:51 +0200 Subject: Implement support for mixed auto/manual id assignment in SQLite Now one can do: #pragma db id auto odb::nullable id; And then set the id to NULL to get auto-assignment or to the actual value to use a manual id. --- odb/relational/mysql/source.cxx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'odb/relational/mysql/source.cxx') diff --git a/odb/relational/mysql/source.cxx b/odb/relational/mysql/source.cxx index 65ff711..af37598 100644 --- a/odb/relational/mysql/source.cxx +++ b/odb/relational/mysql/source.cxx @@ -679,7 +679,8 @@ namespace relational virtual void init_auto_id (semantics::data_member&, string const& im) { - os << im << "value = 0;"; + os << im << "value = 0;" + << endl; } virtual string -- cgit v1.1