MCPcopy Create free account
hub / github.com/ClickHouse/ClickHouse / checkTypesOfMasks

Function checkTypesOfMasks

src/Interpreters/JoinUtils.cpp:418–435  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

416}
417
418void checkTypesOfMasks(const Block & block_left, const String & condition_name_left,
419 const Block & block_right, const String & condition_name_right)
420{
421 auto check_cond_column_type = [](const Block & block, const String & col_name)
422 {
423 if (col_name.empty())
424 return;
425
426 DataTypePtr dtype = block.getByName(col_name).type;
427
428 if (!dtype->canBeUsedInBooleanContext())
429 throw Exception(ErrorCodes::INVALID_JOIN_ON_EXPRESSION,
430 "Expected logical expression in JOIN ON section, got unexpected column '{}' of type '{}'",
431 col_name, dtype->getName());
432 };
433 check_cond_column_type(block_left, condition_name_left);
434 check_cond_column_type(block_right, condition_name_right);
435}
436
437void createMissedColumns(Block & block)
438{

Callers 3

checkTypesOfKeysFunction · 0.85
MergeJoinMethod · 0.85
joinBlockMethod · 0.85

Calls 5

getByNameMethod · 0.80
ExceptionClass · 0.70
emptyMethod · 0.45
getNameMethod · 0.45

Tested by

no test coverage detected