diff --git a/include/sqlpp11/any.h b/include/sqlpp11/any.h index e4c9ceef..a5955455 100644 --- a/include/sqlpp11/any.h +++ b/include/sqlpp11/any.h @@ -57,7 +57,7 @@ namespace sqlpp }; }; - using _table_set = ::sqlpp::detail::type_set<>; // FIXME: Can selects leak tables here? + using _table_set = typename Select::_table_set; any_t(Select select): _select(select) diff --git a/include/sqlpp11/remove.h b/include/sqlpp11/remove.h index a0673934..93807f8f 100644 --- a/include/sqlpp11/remove.h +++ b/include/sqlpp11/remove.h @@ -175,7 +175,7 @@ namespace sqlpp template auto _prepare(Db& db) const - -> prepared_remove_t + -> prepared_remove_t { //static_assert(detail::check_remove_t::value, "Cannot run this remove expression"); return {{}, db.prepare_remove(*this)}; @@ -195,7 +195,7 @@ namespace sqlpp static Context& _(const T& t, Context& context) { - context << "DELETE FROM"; + context << "DELETE FROM "; interpret(t._table, context); interpret(t._using, context); interpret(t._where, context); diff --git a/include/sqlpp11/some.h b/include/sqlpp11/some.h index c9f26081..268ec963 100644 --- a/include/sqlpp11/some.h +++ b/include/sqlpp11/some.h @@ -27,8 +27,8 @@ #ifndef SQLPP_SOME_H #define SQLPP_SOME_H -#include #include +#include namespace sqlpp { @@ -56,6 +56,7 @@ namespace sqlpp const T& operator()() const { return some; } }; }; + using _table_set = typename Select::_table_set; some_t(Select select): _select(select) diff --git a/include/sqlpp11/update.h b/include/sqlpp11/update.h index a26a34aa..7485a453 100644 --- a/include/sqlpp11/update.h +++ b/include/sqlpp11/update.h @@ -178,7 +178,7 @@ namespace sqlpp template auto _prepare(Db& db) const - -> prepared_update_t + -> prepared_update_t { return {{}, db.prepare_update(*this)}; } diff --git a/include/sqlpp11/vendor/insert_value_list.h b/include/sqlpp11/vendor/insert_value_list.h index 9959c823..aa16d582 100644 --- a/include/sqlpp11/vendor/insert_value_list.h +++ b/include/sqlpp11/vendor/insert_value_list.h @@ -29,6 +29,8 @@ #include #include +#include +#include #include #include #include diff --git a/include/sqlpp11/vendor/is_null.h b/include/sqlpp11/vendor/is_null.h index 7b7dab61..6095fb89 100644 --- a/include/sqlpp11/vendor/is_null.h +++ b/include/sqlpp11/vendor/is_null.h @@ -39,6 +39,7 @@ namespace sqlpp struct is_null_t: public boolean::template operators> { static constexpr bool _inverted = not NotInverted; + using _table_set = typename Operand::_table_set; struct _value_type: public boolean {