ClickHouse/src/Interpreters/addTypeConversionToAST.h
2021-06-01 15:20:52 +03:00

20 lines
499 B
C++

#pragma once
#include <Interpreters/Context_fwd.h>
#include <Parsers/IAST_fwd.h>
#include <common/types.h>
namespace DB
{
class NamesAndTypesList;
/// It will produce an expression with CAST to get an AST with the required type.
ASTPtr addTypeConversionToAST(ASTPtr && ast, const String & type_name);
// If same type, then ignore the wrapper of CAST function
ASTPtr addTypeConversionToAST(ASTPtr && ast, const String & type_name, const NamesAndTypesList & all_columns, ContextPtr context);
}