2020-11-26 18:16:07 +00:00
|
|
|
#include "FunctionsStringSearch.h"
|
|
|
|
#include "FunctionFactory.h"
|
|
|
|
#include "CountSubstringsImpl.h"
|
|
|
|
|
|
|
|
|
|
|
|
namespace DB
|
|
|
|
{
|
|
|
|
namespace
|
|
|
|
{
|
|
|
|
|
|
|
|
struct NameCountSubstrings
|
|
|
|
{
|
|
|
|
static constexpr auto name = "countSubstrings";
|
|
|
|
};
|
|
|
|
|
2021-09-21 16:43:46 +00:00
|
|
|
using FunctionCountSubstrings = FunctionsStringSearch<CountSubstringsImpl<NameCountSubstrings, PositionCaseSensitiveASCII>>;
|
2020-11-26 18:16:07 +00:00
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
void registerFunctionCountSubstrings(FunctionFactory & factory)
|
|
|
|
{
|
|
|
|
factory.registerFunction<FunctionCountSubstrings>(FunctionFactory::CaseInsensitive);
|
|
|
|
}
|
|
|
|
}
|