mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-25 17:12:03 +00:00
Addition to prev. revision [#CLICKHOUSE-3402].
This commit is contained in:
parent
ec5720eb66
commit
ac1b69247c
@ -370,7 +370,6 @@ int main(int argc, char ** argv)
|
||||
for (size_t arity = 2; arity <= columns; ++arity)
|
||||
{
|
||||
FunctionPtr function = std::make_shared<FunctionAnd>();
|
||||
function->getReturnType(DataTypes(arity, DataTypePtr(std::make_shared<DataTypeUInt8>())));
|
||||
|
||||
ColumnNumbers arguments(arity);
|
||||
for (size_t i = 0; i < arity; ++i)
|
||||
|
@ -307,11 +307,13 @@ static void applyFunction(
|
||||
const DataTypePtr & arg_type, const Field & arg_value,
|
||||
DataTypePtr & res_type, Field & res_value)
|
||||
{
|
||||
res_type = func->getReturnType({arg_type});
|
||||
std::vector<ExpressionAction> unused_prerequisites;
|
||||
ColumnsWithTypeAndName arguments{{ arg_type->createConstColumn(1, arg_value), arg_type, "x" }};
|
||||
func->getReturnTypeAndPrerequisites(arguments, res_type, unused_prerequisites);
|
||||
|
||||
Block block
|
||||
{
|
||||
{ arg_type->createConstColumn(1, arg_value), arg_type, "x" },
|
||||
arguments[0],
|
||||
{ nullptr, res_type, "y" }
|
||||
};
|
||||
|
||||
@ -435,7 +437,10 @@ bool PKCondition::isPrimaryKeyPossiblyWrappedByMonotonicFunctions(
|
||||
if (!func || !func->hasInformationAboutMonotonicity())
|
||||
return false;
|
||||
|
||||
primary_key_column_type = func->getReturnType({primary_key_column_type});
|
||||
std::vector<ExpressionAction> unused_prerequisites;
|
||||
ColumnsWithTypeAndName arguments{{ nullptr, primary_key_column_type, "" }};
|
||||
func->getReturnTypeAndPrerequisites(arguments, primary_key_column_type, unused_prerequisites);
|
||||
|
||||
out_functions_chain.push_back(func);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user