mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-12-13 18:02:24 +00:00
28 lines
735 B
C++
28 lines
735 B
C++
#include <Parsers/ASTQualifiedAsterisk.h>
|
|
#include <IO/WriteHelpers.h>
|
|
#include <IO/Operators.h>
|
|
|
|
namespace DB
|
|
{
|
|
|
|
void ASTQualifiedAsterisk::appendColumnName(WriteBuffer & ostr) const
|
|
{
|
|
const auto & qualifier = children.at(0);
|
|
qualifier->appendColumnName(ostr);
|
|
writeCString(".*", ostr);
|
|
}
|
|
|
|
void ASTQualifiedAsterisk::formatImpl(const FormatSettings & settings, FormatState & state, FormatStateStacked frame) const
|
|
{
|
|
const auto & qualifier = children.at(0);
|
|
qualifier->formatImpl(settings, state, frame);
|
|
settings.ostr << ".*";
|
|
for (ASTs::const_iterator it = children.begin() + 1; it != children.end(); ++it)
|
|
{
|
|
settings.ostr << ' ';
|
|
(*it)->formatImpl(settings, state, frame);
|
|
}
|
|
}
|
|
|
|
}
|