diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2011-03-24 12:35:08 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2011-03-24 12:35:08 +0200 |
commit | 8f59ca1a8d7093655f8f7d61f101abc6df3839d5 (patch) | |
tree | 2555c001df7b81560bdc3c579f8c84260c168203 /odb/relational/mysql/source.cxx | |
parent | 9cb4ce54829fb2f091e8690b591440b4369a1387 (diff) |
Generalization work for MySQL and SQLite support
Diffstat (limited to 'odb/relational/mysql/source.cxx')
-rw-r--r-- | odb/relational/mysql/source.cxx | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/odb/relational/mysql/source.cxx b/odb/relational/mysql/source.cxx index a205650..cf26082 100644 --- a/odb/relational/mysql/source.cxx +++ b/odb/relational/mysql/source.cxx @@ -265,7 +265,7 @@ namespace relational return false; ostringstream ostr; - ostr << "e[" << index_ << "UL]"; + ostr << "t[" << index_ << "UL]"; e = ostr.str (); if (var_override_.empty ()) @@ -289,7 +289,7 @@ namespace relational { os << "if (composite_value_traits< " << mi.fq_type () << " >::grow (" << endl - << "i." << mi.var << "value, e + " << index_ << "UL))" + << "i." << mi.var << "value, t + " << index_ << "UL))" << "{" << "grew = true;" << "}"; @@ -894,6 +894,18 @@ namespace relational member_database_type_id member_database_type_id_; }; entry<init_value_member> init_value_member_; + + struct class_: relational::class_, context + { + class_ (base const& x): base (x) {} + + virtual void + init_auto_id (semantics::data_member&, string const& im) + { + os << im << "value = 0;"; + } + }; + entry<class_> class_entry_; } } } |