ClickHouse/src/Functions/countMatches.cpp
2024-07-17 20:56:30 +00:00

30 lines
618 B
C++

#include "FunctionFactory.h"
#include "countMatches.h"
namespace
{
struct FunctionCountMatchesCaseSensitive
{
static constexpr auto name = "countMatches";
static constexpr bool case_insensitive = false;
};
struct FunctionCountMatchesCaseInsensitive
{
static constexpr auto name = "countMatchesCaseInsensitive";
static constexpr bool case_insensitive = true;
};
}
namespace DB
{
REGISTER_FUNCTION(CountMatches)
{
factory.registerFunction<FunctionCountMatches<FunctionCountMatchesCaseSensitive>>();
factory.registerFunction<FunctionCountMatches<FunctionCountMatchesCaseInsensitive>>();
}
}