mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-12-03 04:52:10 +00:00
18 lines
492 B
C++
18 lines
492 B
C++
|
#pragma once
|
||
|
|
||
|
#include <string>
|
||
|
#include <Parsers/IAST.h>
|
||
|
#include "IDataType.h"
|
||
|
|
||
|
namespace DB
|
||
|
{
|
||
|
/// Convert data type to query. for example
|
||
|
/// DataTypeUInt8 -> ASTIdentifier(UInt8)
|
||
|
/// DataTypeNullable(DataTypeUInt8) -> ASTFunction(ASTIdentifier(UInt8))
|
||
|
ASTPtr dataTypeConvertToQuery(const DataTypePtr & data_type);
|
||
|
|
||
|
/// Convert MySQL type to ClickHouse data type.
|
||
|
DataTypePtr convertMySQLDataType(const std::string & mysql_data_type, bool is_nullable, bool is_unsigned, size_t length);
|
||
|
|
||
|
}
|