mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-23 16:12:01 +00:00
mysqlxx: added missing file.
This commit is contained in:
parent
eb9f0512ed
commit
5533bf9ba9
22
libs/libmysqlxx/src/String.cpp
Normal file
22
libs/libmysqlxx/src/String.cpp
Normal file
@ -0,0 +1,22 @@
|
||||
#include <mysqlxx/String.h>
|
||||
#include <mysqlxx/ResultBase.h>
|
||||
#include <mysqlxx/Query.h>
|
||||
#include <mysqlxx/Exception.h>
|
||||
|
||||
|
||||
void mysqlxx::String::throwException(const char * text) const
|
||||
{
|
||||
std::stringstream info;
|
||||
info << text;
|
||||
|
||||
if (!isNull())
|
||||
{
|
||||
info << ": ";
|
||||
info.write(m_data, m_length);
|
||||
}
|
||||
|
||||
if (res && res->getQuery())
|
||||
info << ", query: " << res->getQuery()->str().substr(0, MYSQLXX_QUERY_PREVIEW_LENGTH);
|
||||
|
||||
throw CannotParseValue(info.str());
|
||||
}
|
Loading…
Reference in New Issue
Block a user