mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-12-14 18:32:29 +00:00
21 lines
390 B
C++
21 lines
390 B
C++
#include <Functions/FunctionFactory.h>
|
|
#include <Functions/FunctionsRandom.h>
|
|
|
|
namespace DB
|
|
{
|
|
namespace
|
|
{
|
|
|
|
struct NameRand { static constexpr auto name = "rand"; };
|
|
using FunctionRand = FunctionRandom<UInt32, NameRand>;
|
|
|
|
}
|
|
|
|
REGISTER_FUNCTION(Rand)
|
|
{
|
|
factory.registerFunction<FunctionRand>({}, FunctionFactory::CaseInsensitive);
|
|
factory.registerAlias("rand32", NameRand::name);
|
|
}
|
|
|
|
}
|