2017-04-01 09:19:00 +00:00
|
|
|
#include <Functions/FunctionFactory.h>
|
|
|
|
#include <Functions/FunctionsRound.h>
|
2014-08-22 00:57:20 +00:00
|
|
|
|
|
|
|
namespace DB
|
|
|
|
{
|
|
|
|
|
|
|
|
void registerFunctionsRound(FunctionFactory & factory)
|
|
|
|
{
|
2017-04-01 07:20:54 +00:00
|
|
|
factory.registerFunction<FunctionRoundToExp2>();
|
|
|
|
factory.registerFunction<FunctionRoundDuration>();
|
|
|
|
factory.registerFunction<FunctionRoundAge>();
|
2017-09-16 22:11:20 +00:00
|
|
|
|
|
|
|
factory.registerFunction("round", FunctionRound::create, FunctionFactory::CaseInsensitive);
|
|
|
|
factory.registerFunction("floor", FunctionFloor::create, FunctionFactory::CaseInsensitive);
|
|
|
|
factory.registerFunction("ceil", FunctionCeil::create, FunctionFactory::CaseInsensitive);
|
|
|
|
factory.registerFunction("trunc", FunctionTrunc::create, FunctionFactory::CaseInsensitive);
|
|
|
|
|
|
|
|
/// Compatibility aliases.
|
|
|
|
factory.registerFunction("ceiling", FunctionCeil::create, FunctionFactory::CaseInsensitive);
|
|
|
|
factory.registerFunction("truncate", FunctionTrunc::create, FunctionFactory::CaseInsensitive);
|
2014-08-22 00:57:20 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
}
|