mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-12-15 02:41:59 +00:00
23 lines
842 B
C++
23 lines
842 B
C++
#include <Functions/FunctionFactory.h>
|
|
#include <Functions/FunctionsRound.h>
|
|
|
|
|
|
namespace DB
|
|
{
|
|
|
|
REGISTER_FUNCTION(Round)
|
|
{
|
|
factory.registerFunction<FunctionRound>("round", {}, FunctionFactory::CaseInsensitive);
|
|
factory.registerFunction<FunctionRoundBankers>("roundBankers", {}, FunctionFactory::CaseSensitive);
|
|
factory.registerFunction<FunctionFloor>("floor", {}, FunctionFactory::CaseInsensitive);
|
|
factory.registerFunction<FunctionCeil>("ceil", {}, FunctionFactory::CaseInsensitive);
|
|
factory.registerFunction<FunctionTrunc>("trunc", {}, FunctionFactory::CaseInsensitive);
|
|
factory.registerFunction<FunctionRoundDown>();
|
|
|
|
/// Compatibility aliases.
|
|
factory.registerAlias("ceiling", "ceil", FunctionFactory::CaseInsensitive);
|
|
factory.registerAlias("truncate", "trunc", FunctionFactory::CaseInsensitive);
|
|
}
|
|
|
|
}
|