-
Notifications
You must be signed in to change notification settings - Fork 8.3k
Array join: Function writeSlice expects same column types for GenericArraySlice and GenericArraySink #57243
Copy link
Copy link
Closed
Labels
bugConfirmed user-visible misbehaviour in official releaseConfirmed user-visible misbehaviour in official releasefuzzProblem found by one of the fuzzersProblem found by one of the fuzzers
Description
Found while testing #57183
CREATE TABLE arrays_test
(
`s` String,
`arr1` Array(LowCardinality(UInt8)),
`map1` Map(UInt8, String),
`map2` Map(UInt8, String)
)
ENGINE = Log();
INSERT INTO arrays_test
VALUES ('Hello', [1,2], map(1, '1', 2, '2'), map(1, '1')), ('World', [3,4,5], map(3, '3', 4, '4', 5, '5'), map(3, '3', 4, '4')), ('Goodbye', [], map(), map());
select s, arr1, map1 from (Select s, range(0, 100000)::Array(LowCardinality(UInt64)) as arr1, map1, map2 FROM arrays_test) array join arr1, map1 settings enable_unaligned_array_join = 1;
executeQuery: Code: 49. DB::Exception: Function writeSlice expects same column types for GenericArraySlice and GenericArraySink.: While executing ArrayJoinTransform. (LOGICAL_ERROR) (version 23.11.1.1)
Backtrace:
2023.11.27 10:00:03.033949 [ 90156 ] {9274049e-4de3-4259-ab8d-7c92f8bffeae} <Error> executeQuery: Code: 49. DB::Exception: Function writeSlice expects same column types for GenericArraySlice and GenericArraySink.: While executing ArrayJoinTransform. (LOGICAL_ERROR) (version 23.11.1.1) (from 192.168.1.200:47002) (in query: select s, arr1, map1 from (Select s, range(0, 100000)::Array(LowCardinality(UInt64)) as arr1, map1, map2 FROM arrays_test) array join arr1, map1 settings enable_unaligned_array_join = 1;), Stack trace (when copying this message, always include the lines below):
0. ./contrib/llvm-project/libcxx/include/exception:134: Poco::Exception::Exception(String const&, int) @ 0x0000000014a6e7b2 in /mnt/ch/ClickHouse/build_default/programs/clickhouse
1. ./build/./src/Common/Exception.cpp:97: DB::Exception::Exception(DB::Exception::MessageMasked&&, int, bool) @ 0x000000000b723ca5 in /mnt/ch/ClickHouse/build_default/programs/clickhouse
2. DB::Exception::Exception<char const (&) [90]>(int, char const (&) [90]) @ 0x0000000007a4f500 in /mnt/ch/ClickHouse/build_default/programs/clickhouse
3. void DB::GatherUtils::resizeDynamicSize<DB::GatherUtils::GenericArraySource&, DB::GatherUtils::ConstSource<DB::GatherUtils::GenericValueSource>&, DB::GatherUtils::GenericArraySink&>(DB::GatherUtils::GenericArraySource&, DB::GatherUtils::ConstSource<DB::GatherUtils::GenericValueSource>&, DB::GatherUtils::GenericArraySink&, DB::IColumn const&) @ 0x000000000f1d4970 in /mnt/ch/ClickHouse/build_default/programs/clickhouse
4. DB::GatherUtils::resizeDynamicSize(DB::GatherUtils::IArraySource&, DB::GatherUtils::IValueSource&, DB::GatherUtils::IArraySink&, DB::IColumn const&) @ 0x000000000f16fbb5 in /mnt/ch/ClickHouse/build_default/programs/clickhouse
5. DB::FunctionArrayResize::executeImpl(std::vector<DB::ColumnWithTypeAndName, std::allocator<DB::ColumnWithTypeAndName>> const&, std::shared_ptr<DB::IDataType const> const&, unsigned long) const @ 0x000000000b3bdaaa in /mnt/ch/ClickHouse/build_default/programs/clickhouse
6. DB::FunctionToExecutableFunctionAdaptor::executeImpl(std::vector<DB::ColumnWithTypeAndName, std::allocator<DB::ColumnWithTypeAndName>> const&, std::shared_ptr<DB::IDataType const> const&, unsigned long) const @ 0x00000000065be2ce in /mnt/ch/ClickHouse/build_default/programs/clickhouse
7. ./build/./src/Functions/IFunction.cpp:0: DB::IExecutableFunction::executeWithoutLowCardinalityColumns(std::vector<DB::ColumnWithTypeAndName, std::allocator<DB::ColumnWithTypeAndName>> const&, std::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const @ 0x000000000f6b6576 in /mnt/ch/ClickHouse/build_default/programs/clickhouse
8. ./contrib/boost/boost/smart_ptr/intrusive_ptr.hpp:117: DB::IExecutableFunction::executeWithoutSparseColumns(std::vector<DB::ColumnWithTypeAndName, std::allocator<DB::ColumnWithTypeAndName>> const&, std::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const @ 0x000000000f6b6fcb in /mnt/ch/ClickHouse/build_default/programs/clickhouse
9. ./build/./src/Functions/IFunction.cpp:378: DB::IExecutableFunction::execute(std::vector<DB::ColumnWithTypeAndName, std::allocator<DB::ColumnWithTypeAndName>> const&, std::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const @ 0x000000000f6b831b in /mnt/ch/ClickHouse/build_default/programs/clickhouse
10. DB::IFunctionBase::execute(std::vector<DB::ColumnWithTypeAndName, std::allocator<DB::ColumnWithTypeAndName>> const&, std::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const @ 0x00000000065bd41a in /mnt/ch/ClickHouse/build_default/programs/clickhouse
11. ./contrib/boost/boost/smart_ptr/intrusive_ptr.hpp:117: DB::ArrayJoinResultIterator::ArrayJoinResultIterator(DB::ArrayJoinAction const*, DB::Block) @ 0x0000000010485434 in /mnt/ch/ClickHouse/build_default/programs/clickhouse
12. ./contrib/llvm-project/libcxx/include/__memory/unique_ptr.h:0: std::__unique_if<DB::ArrayJoinResultIterator>::__unique_single std::make_unique[abi:v15000]<DB::ArrayJoinResultIterator, DB::ArrayJoinAction*, DB::Block>(DB::ArrayJoinAction*&&, DB::Block&&) @ 0x0000000010486e5f in /mnt/ch/ClickHouse/build_default/programs/clickhouse
13. ./build/./src/Interpreters/ArrayJoinAction.cpp:102: DB::ArrayJoinAction::execute(DB::Block) @ 0x0000000010483acb in /mnt/ch/ClickHouse/build_default/programs/clickhouse
14. ./contrib/llvm-project/libcxx/include/__memory/unique_ptr.h:302: DB::ArrayJoinTransform::consume(DB::Chunk) @ 0x00000000123e00ce in /mnt/ch/ClickHouse/build_default/programs/clickhouse
15. ./contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:701: DB::IInflatingTransform::work() @ 0x00000000123e2757 in /mnt/ch/ClickHouse/build_default/programs/clickhouse
16. ./build/./src/Processors/Executors/ExecutionThreadContext.cpp:0: DB::ExecutionThreadContext::executeTask() @ 0x00000000120372e9 in /mnt/ch/ClickHouse/build_default/programs/clickhouse
17. ./build_default/./src/Processors/Executors/PipelineExecutor.cpp:273: DB::PipelineExecutor::executeStepImpl(unsigned long, std::atomic<bool>*) @ 0x000000001202e790 in /mnt/ch/ClickHouse/build_default/programs/clickhouse
18. ./contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:833: void std::__function::__policy_invoker<void ()>::__call_impl<std::__function::__default_alloc_func<DB::PipelineExecutor::spawnThreads()::$_0, void ()>>(std::__function::__policy_storage const*) @ 0x000000001202f507 in /mnt/ch/ClickHouse/build_default/programs/clickhouse
19. ./base/base/../base/wide_integer_impl.h:809: ThreadPoolImpl<ThreadFromGlobalPoolImpl<false>>::worker(std::__list_iterator<ThreadFromGlobalPoolImpl<false>, void*>) @ 0x000000000b7f9158 in /mnt/ch/ClickHouse/build_default/programs/clickhouse
20. ./build/./src/Common/ThreadPool.cpp:0: ThreadFromGlobalPoolImpl<false>::ThreadFromGlobalPoolImpl<void ThreadPoolImpl<ThreadFromGlobalPoolImpl<false>>::scheduleImpl<void>(std::function<void ()>, Priority, std::optional<unsigned long>, bool)::'lambda0'()>(void&&)::'lambda'()::operator()() @ 0x000000000b7fbf8f in /mnt/ch/ClickHouse/build_default/programs/clickhouse
21. ./base/base/../base/wide_integer_impl.h:809: ThreadPoolImpl<std::thread>::worker(std::__list_iterator<std::thread, void*>) @ 0x000000000b7f63c0 in /mnt/ch/ClickHouse/build_default/programs/clickhouse
22. ./contrib/llvm-project/libcxx/include/__memory/unique_ptr.h:302: void* std::__thread_proxy[abi:v15000]<std::tuple<std::unique_ptr<std::__thread_struct, std::default_delete<std::__thread_struct>>, void ThreadPoolImpl<std::thread>::scheduleImpl<void>(std::function<void ()>, Priority, std::optional<unsigned long>, bool)::'lambda0'()>>(void*) @ 0x000000000b7fad20 in /mnt/ch/ClickHouse/build_default/programs/clickhouse
23. ? @ 0x00007fbdf22299eb in ?
24. ? @ 0x00007fbdf22ad7cc in ?
Reproduces in any 23.X release and master/HEAD
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugConfirmed user-visible misbehaviour in official releaseConfirmed user-visible misbehaviour in official releasefuzzProblem found by one of the fuzzersProblem found by one of the fuzzers