Fix the actual_bind versions for integrals
This commit is contained in:
+1
-11
@@ -6,7 +6,7 @@ void actual_bind(Statement& statement, const std::string& value, int index)
|
|||||||
statement.bind_text(index, value);
|
statement.bind_text(index, value);
|
||||||
}
|
}
|
||||||
|
|
||||||
void actual_bind(Statement& statement, const std::int64_t value, int index)
|
void actual_bind(Statement& statement, const std::int64_t& value, int index)
|
||||||
{
|
{
|
||||||
statement.bind_int64(index, value);
|
statement.bind_int64(index, value);
|
||||||
}
|
}
|
||||||
@@ -21,16 +21,6 @@ void actual_bind(Statement& statement, const OptionalBool& value, int index)
|
|||||||
statement.bind_int64(index, -1);
|
statement.bind_int64(index, -1);
|
||||||
}
|
}
|
||||||
|
|
||||||
void actual_bind(Statement& statement, const std::size_t value, int index)
|
|
||||||
{
|
|
||||||
actual_bind(statement, static_cast<std::int64_t>(value), index);
|
|
||||||
}
|
|
||||||
|
|
||||||
void actual_bind(Statement& statement, const int value, int index)
|
|
||||||
{
|
|
||||||
actual_bind(statement, static_cast<std::int64_t>(value), index);
|
|
||||||
}
|
|
||||||
|
|
||||||
void actual_add_param(Query& query, const std::string& val)
|
void actual_add_param(Query& query, const std::string& val)
|
||||||
{
|
{
|
||||||
query.params.push_back(val);
|
query.params.push_back(val);
|
||||||
|
|||||||
@@ -12,9 +12,12 @@
|
|||||||
#include <string>
|
#include <string>
|
||||||
|
|
||||||
void actual_bind(Statement& statement, const std::string& value, int index);
|
void actual_bind(Statement& statement, const std::string& value, int index);
|
||||||
void actual_bind(Statement& statement, const std::int64_t value, int index);
|
void actual_bind(Statement& statement, const std::int64_t& value, int index);
|
||||||
void actual_bind(Statement& statement, const std::size_t value, int index);
|
template <typename T, typename std::enable_if_t<std::is_integral<T>::value>* = 0>
|
||||||
void actual_bind(Statement& statement, const int value, int index);
|
void actual_bind(Statement& statement, const T& value, int index)
|
||||||
|
{
|
||||||
|
actual_bind(statement, static_cast<std::int64_t>(value), index);
|
||||||
|
}
|
||||||
void actual_bind(Statement& statement, const OptionalBool& value, int index);
|
void actual_bind(Statement& statement, const OptionalBool& value, int index);
|
||||||
|
|
||||||
#ifdef DEBUG_SQL_QUERIES
|
#ifdef DEBUG_SQL_QUERIES
|
||||||
|
|||||||
Reference in New Issue
Block a user