mirror of
https://github.com/rbock/sqlpp11.git
synced 2024-11-16 04:47:18 +08:00
Test with boolean and text parameters in prepared query compiles and runs
with mysql
This commit is contained in:
parent
c140e13510
commit
409fa3baac
@ -113,6 +113,12 @@ namespace sqlpp
|
|||||||
|
|
||||||
operator _cpp_value_type() const { return value(); }
|
operator _cpp_value_type() const { return value(); }
|
||||||
|
|
||||||
|
template<typename Target>
|
||||||
|
void bind(Target& target, size_t index) const
|
||||||
|
{
|
||||||
|
target.bind_boolean_parameter(index, &_value, _is_null);
|
||||||
|
}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
bool _trivial_value_is_null;
|
bool _trivial_value_is_null;
|
||||||
signed char _value;
|
signed char _value;
|
||||||
|
@ -102,6 +102,12 @@ namespace sqlpp
|
|||||||
|
|
||||||
operator _cpp_value_type() const { return value(); }
|
operator _cpp_value_type() const { return value(); }
|
||||||
|
|
||||||
|
template<typename Target>
|
||||||
|
void bind(Target& target, size_t index) const
|
||||||
|
{
|
||||||
|
target.bind_text_parameter(index, &_value, _is_null);
|
||||||
|
}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
bool _trivial_value_is_null;
|
bool _trivial_value_is_null;
|
||||||
_cpp_value_type _value;
|
_cpp_value_type _value;
|
||||||
|
Loading…
Reference in New Issue
Block a user