1 | #include <DataTypes/DataTypeString.h> |
---|---|
2 | #include <Functions/FunctionFactory.h> |
3 | #include <Functions/FunctionStringToString.h> |
4 | #include <Functions/LowerUpperImpl.h> |
5 | |
6 | |
7 | namespace DB |
8 | { |
9 | |
10 | struct NameLower |
11 | { |
12 | static constexpr auto name = "lower"; |
13 | }; |
14 | using FunctionLower = FunctionStringToString<LowerUpperImpl<'A', 'Z'>, NameLower>; |
15 | |
16 | void registerFunctionLower(FunctionFactory & factory) |
17 | { |
18 | factory.registerFunction<FunctionLower>(FunctionFactory::CaseInsensitive); |
19 | factory.registerAlias("lcase", NameLower::name, FunctionFactory::CaseInsensitive); |
20 | } |
21 | |
22 | } |
23 |