Fix build and style

This commit is contained in:
avogar 2024-07-20 19:10:08 +00:00
parent 74670e7d20
commit 184405fc7a
5 changed files with 10 additions and 9 deletions

View File

@ -478,7 +478,7 @@ static DataTypePtr createJSON(const ASTPtr & arguments)
void registerDataTypeJSON(DataTypeFactory & factory)
{
if (!Context::getGlobalContextInstance()->getSettingsRef().use_json_alias_for_old_object_type)
factory.registerDataType("JSON", createJSON, DataTypeFactory::CaseInsensitive);
factory.registerDataType("JSON", createJSON, DataTypeFactory::Case::Insensitive);
}
}

View File

@ -10,11 +10,6 @@
namespace DB
{
namespace ErrorCodes
{
extern const int NOT_IMPLEMENTED;
}
class DataTypeObject : public IDataType
{
public:

View File

@ -80,7 +80,7 @@ void registerDataTypeObjectDeprecated(DataTypeFactory & factory)
if (Context::getGlobalContextInstance()->getSettingsRef().use_json_alias_for_old_object_type)
factory.registerSimpleDataType("JSON",
[] { return std::make_shared<DataTypeObjectDeprecated>("JSON", false); },
DataTypeFactory::CaseInsensitive);
DataTypeFactory::Case::Insensitive);
}
}

View File

@ -96,7 +96,7 @@ public:
DataTypePtr getReturnTypeImpl(const DataTypes & data_types) const override
{
if (data_types.size() != 1 )
if (data_types.size() != 1)
throw Exception(ErrorCodes::NUMBER_OF_ARGUMENTS_DOESNT_MATCH, "Function {} requires single argument with type JSON", getName());
if (data_types[0]->getTypeId() != TypeIndex::Object)
@ -152,7 +152,7 @@ private:
for (const auto & path : dynamic_paths)
{
/// Don't include path if it contains NULL, because we consider
/// it to be equivalent to the absense of this path in this row.
/// it to be equivalent to the absence of this path in this row.
if (!dynamic_path_columns.at(path)->isNullAt(i))
data.insertData(path.data(), path.size());
}

View File

@ -390,6 +390,8 @@ IsValid
JBOD
JOINed
JOINs
JSONAllPaths
JSONAllPathsWithTypes
JSONArrayLength
JSONAsObject
JSONAsString
@ -404,6 +406,8 @@ JSONCompactStrings
JSONCompactStringsEachRow
JSONCompactStringsEachRowWithNames
JSONCompactStringsEachRowWithNamesAndTypes
JSONDynamicPaths
JSONDynamicPathsWithTypes
JSONEachRow
JSONEachRowWithProgress
JSONExtract
@ -423,6 +427,8 @@ JSONObjectEachRow
JSONStrings
JSONStringsEachRow
JSONStringsEachRowWithProgress
JSONSharedDataPaths
JSONSharedDataPathsWithTypes
JSONType
JSONs
Jaeger