0
0
mirror of https://github.com/rbock/sqlpp11.git synced 2024-11-16 04:47:18 +08:00

Split dynamic where in a specific one for zero arguments (and the old one)

This commit is contained in:
rbock 2015-12-28 10:11:18 +01:00
parent 6ae63dd0be
commit d1cc617ae7

View File

@ -331,6 +331,14 @@ namespace sqlpp
return _where_impl<void>(Check{}, expressions...); return _where_impl<void>(Check{}, expressions...);
} }
auto dynamic_where() const -> _new_statement_t<check_where_dynamic_t<_database_t>, where_t<_database_t>>
{
using Check = check_where_dynamic_t<_database_t>;
Check{}._();
return _where_impl<_database_t>(Check{});
}
template <typename... Expressions> template <typename... Expressions>
auto dynamic_where(Expressions... expressions) const auto dynamic_where(Expressions... expressions) const
-> _new_statement_t<check_where_dynamic_t<_database_t, Expressions...>, where_t<_database_t, Expressions...>> -> _new_statement_t<check_where_dynamic_t<_database_t, Expressions...>, where_t<_database_t, Expressions...>>