mirror of
https://github.com/pocoproject/poco.git
synced 2025-10-24 09:12:28 +02:00
Handle MariaDB JSON columns since they are stored as longtext (#3621)
* Also extract BLOBs when reading longtext columns as std::string * Fix error message in unit test * Added unit test to read longtext columns as std::string
This commit is contained in:
@@ -134,6 +134,9 @@ bool Extractor::extract(std::size_t pos, std::string& val)
|
||||
if (columnType == Poco::Data::MetaColumn::FDT_JSON && !extractJSON(pos))
|
||||
return false;
|
||||
|
||||
if (columnType == Poco::Data::MetaColumn::FDT_BLOB && !extractLongLOB(pos))
|
||||
return false;
|
||||
|
||||
val.assign(reinterpret_cast<const char*>(_metadata.rawData(pos)), _metadata.length(pos));
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user