mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-12-14 18:32:29 +00:00
22 lines
467 B
C++
22 lines
467 B
C++
#include <Interpreters/Context.h>
|
|
#include <Storages/System/StorageSystemWarnings.h>
|
|
|
|
|
|
namespace DB
|
|
{
|
|
|
|
NamesAndTypesList StorageSystemWarnings::getNamesAndTypes()
|
|
{
|
|
return {
|
|
{"message", std::make_shared<DataTypeString>()},
|
|
};
|
|
}
|
|
|
|
void StorageSystemWarnings::fillData(MutableColumns & res_columns, ContextPtr context, const SelectQueryInfo &) const
|
|
{
|
|
for (const auto & warning : context->getWarnings())
|
|
res_columns[0]->insert(warning);
|
|
}
|
|
|
|
}
|