```
select in((1, 1, 1, 1))



2020.07.15 15:05:10.197400 [ 329628 ] {2a5245f6-5d2a-4662-a05d-4eae5797efdb} <Error> executeQuery: std::exception. Code: 1001, type: std::out_of_range, e.what() = vector (version 20.7.1.1) (from [::1]:57258) (in query: select in((1, 1, 1, 1))), Stack trace (when copying this message, always include the lines below):

0. /home/akuzm/ch4/ch/contrib/libcxx/include/exception:129: std::exception::capture() @ 0x1c8708 in /home/akuzm/ch4/build-clang10/programs/server/libclickhouse-server-libd.so
1. /home/akuzm/ch4/ch/contrib/libcxx/include/exception:109: std::exception::exception() @ 0x105302 in /home/akuzm/ch4/build-clang10/contrib/libcxx-cmake/libcxxd.so
2. /home/akuzm/ch4/ch/contrib/libcxx/src/support/runtime/stdexcept_default.ipp:24: std::logic_error::logic_error(char const*) @ 0x104f30 in /home/akuzm/ch4/build-clang10/contrib/libcxx-cmake/libcxxd.so
3. /home/akuzm/ch4/ch/contrib/libcxx/include/stdexcept:164: std::out_of_range::out_of_range(char const*) @ 0x64337 in /home/akuzm/ch4/build-clang10/contrib/poco-cmake/JSON/lib_poco_jsond.so
4. /home/akuzm/ch4/ch/contrib/libcxx/include/stdexcept:262: std::__1::__throw_out_of_range(char const*) @ 0x642c9 in /home/akuzm/ch4/build-clang10/contrib/poco-cmake/JSON/lib_poco_jsond.so
5. ? @ 0x64298 in /home/akuzm/ch4/build-clang10/contrib/poco-cmake/JSON/lib_poco_jsond.so
6. /home/akuzm/ch4/ch/contrib/libcxx/include/vector:0: std::__1::vector<std::__1::shared_ptr<DB::IAST>, std::__1::allocator<std::__1::shared_ptr<DB::IAST> > >::at(unsigned long) @ 0x1a5081 in /home/akuzm/ch4/build-clang10/src/TableFunctions/libclickhouse_table_functionsd.so
7. /home/akuzm/ch4/ch/src/Interpreters/MarkTableIdentifiersVisitor.cpp:40: DB::MarkTableIdentifiersMatcher::visit(DB::ASTFunction const&, std::__1::shared_ptr<DB::IAST>&, DB::MarkTableIdentifiersMatcher::Data&) @ 0x16eda1b in /home/akuzm/ch4/build-clang10/src/libclickhouse_interpretersd.so
8. /home/akuzm/ch4/ch/src/Interpreters/MarkTableIdentifiersVisitor.cpp:24: DB::MarkTableIdentifiersMatcher::visit(std::__1::shared_ptr<DB::IAST>&, DB::MarkTableIdentifiersMatcher::Data&) @ 0x16ed971 in /home/akuzm/ch4/build-clang10/src/libclickhouse_interpretersd.so
9. /home/akuzm/ch4/ch/src/Interpreters/InDepthNodeVisitor.h:32: DB::InDepthNodeVisitor<DB::MarkTableIdentifiersMatcher, true, std::__1::shared_ptr<DB::IAST> >::visit(std::__1::shared_ptr<DB::IAST>&) @ 0x18097ed in /home/akuzm/ch4/build-clang10/src/libclickhouse_interpretersd.so
10. /home/akuzm/ch4/ch/src/Interpreters/InDepthNodeVisitor.h:45: DB::InDepthNodeVisitor<DB::MarkTableIdentifiersMatcher, true, std::__1::shared_ptr<DB::IAST> >::visitChildren(std::__1::shared_ptr<DB::IAST>&) @ 0x1817656 in /home/akuzm/ch4/build-clang10/src/libclickhouse_interpretersd.so
11. /home/akuzm/ch4/ch/src/Interpreters/InDepthNodeVisitor.h:35: DB::InDepthNodeVisitor<DB::MarkTableIdentifiersMatcher, true, std::__1::shared_ptr<DB::IAST> >::visit(std::__1::shared_ptr<DB::IAST>&) @ 0x18097ff in /home/akuzm/ch4/build-clang10/src/libclickhouse_interpretersd.so
12. /home/akuzm/ch4/ch/src/Interpreters/InDepthNodeVisitor.h:45: DB::InDepthNodeVisitor<DB::MarkTableIdentifiersMatcher, true, std::__1::shared_ptr<DB::IAST> >::visitChildren(std::__1::shared_ptr<DB::IAST>&) @ 0x1817656 in /home/akuzm/ch4/build-clang10/src/libclickhouse_interpretersd.so
13. /home/akuzm/ch4/ch/src/Interpreters/InDepthNodeVisitor.h:35: DB::InDepthNodeVisitor<DB::MarkTableIdentifiersMatcher, true, std::__1::shared_ptr<DB::IAST> >::visit(std::__1::shared_ptr<DB::IAST>&) @ 0x18097ff in /home/akuzm/ch4/build-clang10/src/libclickhouse_interpretersd.so
14. /home/akuzm/ch4/ch/src/Interpreters/SyntaxAnalyzer.cpp:1211: DB::SyntaxAnalyzer::normalize(std::__1::shared_ptr<DB::IAST>&, std::__1::unordered_map<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::shared_ptr<DB::IAST>, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::allocator<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, std::__1::shared_ptr<DB::IAST> > > >&, DB::Settings const&) @ 0x180138c in /home/akuzm/ch4/build-clang10/src/libclickhouse_interpretersd.so
15. /home/akuzm/ch4/ch/src/Interpreters/SyntaxAnalyzer.cpp:1065: DB::SyntaxAnalyzer::analyzeSelect(std::__1::shared_ptr<DB::IAST>&, DB::SyntaxAnalyzerResult&&, DB::SelectQueryOptions const&, std::__1::vector<DB::TableWithColumnNamesAndTypes, std::__1::allocator<DB::TableWithColumnNamesAndTypes> > const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::shared_ptr<DB::TableJoin>) const @ 0x17fff12 in /home/akuzm/ch4/build-clang10/src/libclickhouse_interpretersd.so
16. /home/akuzm/ch4/ch/src/Interpreters/InterpreterSelectQuery.cpp:314: DB::InterpreterSelectQuery::InterpreterSelectQuery(std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, std::__1::shared_ptr<DB::IBlockInputStream> const&, std::__1::optional<DB::Pipe>, std::__1::shared_ptr<DB::IStorage> const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&)::$_2::operator()(bool) const @ 0x1605194 in /home/akuzm/ch4/build-clang10/src/libclickhouse_interpretersd.so
17. /home/akuzm/ch4/ch/src/Interpreters/InterpreterSelectQuery.cpp:405: DB::InterpreterSelectQuery::InterpreterSelectQuery(std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, std::__1::shared_ptr<DB::IBlockInputStream> const&, std::__1::optional<DB::Pipe>, std::__1::shared_ptr<DB::IStorage> const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&) @ 0x160371f in /home/akuzm/ch4/build-clang10/src/libclickhouse_interpretersd.so
18. /home/akuzm/ch4/ch/src/Interpreters/InterpreterSelectQuery.cpp:146: DB::InterpreterSelectQuery::InterpreterSelectQuery(std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) @ 0x160262c in /home/akuzm/ch4/build-clang10/src/libclickhouse_interpretersd.so
19. /home/akuzm/ch4/ch/contrib/libcxx/include/memory:3028: std::__1::__unique_if<DB::InterpreterSelectQuery>::__unique_single std::__1::make_unique<DB::InterpreterSelectQuery, std::__1::shared_ptr<DB::IAST>&, DB::Context&, DB::SelectQueryOptions&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&>(std::__1::shared_ptr<DB::IAST>&, DB::Context&, DB::SelectQueryOptions&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) @ 0x1674bf1 in /home/akuzm/ch4/build-clang10/src/libclickhouse_interpretersd.so
20. /home/akuzm/ch4/ch/src/Interpreters/InterpreterSelectWithUnionQuery.cpp:84: DB::InterpreterSelectWithUnionQuery::InterpreterSelectWithUnionQuery(std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) @ 0x167375a in /home/akuzm/ch4/build-clang10/src/libclickhouse_interpretersd.so
21. /home/akuzm/ch4/ch/contrib/libcxx/include/memory:3028: std::__1::__unique_if<DB::InterpreterSelectWithUnionQuery>::__unique_single std::__1::make_unique<DB::InterpreterSelectWithUnionQuery, std::__1::shared_ptr<DB::IAST>&, DB::Context&, DB::SelectQueryOptions>(std::__1::shared_ptr<DB::IAST>&, DB::Context&, DB::SelectQueryOptions&&) @ 0x15befc5 in /home/akuzm/ch4/build-clang10/src/libclickhouse_interpretersd.so
22. /home/akuzm/ch4/ch/src/Interpreters/InterpreterFactory.cpp:103: DB::InterpreterFactory::get(std::__1::shared_ptr<DB::IAST>&, DB::Context&, DB::QueryProcessingStage::Enum) @ 0x15bdfa3 in /home/akuzm/ch4/build-clang10/src/libclickhouse_interpretersd.so
23. /home/akuzm/ch4/ch/src/Interpreters/executeQuery.cpp:365: DB::executeQueryImpl(char const*, char const*, DB::Context&, bool, DB::QueryProcessingStage::Enum, bool, DB::ReadBuffer*) @ 0x19a1651 in /home/akuzm/ch4/build-clang10/src/libclickhouse_interpretersd.so
24. /home/akuzm/ch4/ch/src/Interpreters/executeQuery.cpp:653: DB::executeQuery(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, DB::Context&, bool, DB::QueryProcessingStage::Enum, bool) @ 0x19a087a in /home/akuzm/ch4/build-clang10/src/libclickhouse_interpretersd.so
25. /home/akuzm/ch4/ch/src/Server/TCPHandler.cpp:253: DB::TCPHandler::runImpl() @ 0x36a874 in /home/akuzm/ch4/build-clang10/src/libclickhouse_serverd.so
26. /home/akuzm/ch4/ch/src/Server/TCPHandler.cpp:1210: DB::TCPHandler::run() @ 0x371dc8 in /home/akuzm/ch4/build-clang10/src/libclickhouse_serverd.so
27. /home/akuzm/ch4/ch/contrib/poco/Net/src/TCPServerConnection.cpp:43: Poco::Net::TCPServerConnection::start() @ 0x1b9d7c in /home/akuzm/ch4/build-clang10/contrib/poco-cmake/Net/lib_poco_netd.so
28. /home/akuzm/ch4/ch/contrib/poco/Net/src/TCPServerDispatcher.cpp:114: Poco::Net::TCPServerDispatcher::run() @ 0x1ba58a in /home/akuzm/ch4/build-clang10/contrib/poco-cmake/Net/lib_poco_netd.so
29. /home/akuzm/ch4/ch/contrib/poco/Foundation/src/ThreadPool.cpp:199: Poco::PooledThread::run() @ 0x276173 in /home/akuzm/ch4/build-clang10/contrib/poco-cmake/Foundation/lib_poco_foundationd.so
30. /home/akuzm/ch4/ch/contrib/poco/Foundation/src/Thread.cpp:56: Poco::(anonymous namespace)::RunnableHolder::run() @ 0x27303d in /home/akuzm/ch4/build-clang10/contrib/poco-cmake/Foundation/lib_poco_foundationd.so
31. /home/akuzm/ch4/ch/contrib/poco/Foundation/src/Thread_POSIX.cpp:345: Poco::ThreadImpl::runnableEntry(void*) @ 0x271eba in /home/akuzm/ch4/build-clang10/contrib/poco-cmake/Foundation/lib_poco_foundationd.so
```
auto argument_name = node.arguments->children.at(0)->getColumnName();
                data.addAction(ExpressionAction::applyFunction(
                        FunctionFactory::instance().get(node.name + "IgnoreSet", data.context),
                        { argument_name, argument_name },
                        column_name.get(ast)));
            }
            return;
        }
    }
    if (AggregateFunctionFactory::instance().isAggregateFunctionName(node.name))
        return;
    
    const Context & function_context = data.context.hasQueryContext()
        ? data.context.getQueryContext()
        : data.context;
    FunctionOverloadResolverPtr function_builder;
    try
    {
        function_builder = FunctionFactory::instance().get(node.name, function_context);
    }
    catch (DB::Exception & e)
    {
        auto hints = AggregateFunctionFactory::instance().getHints(node.name);
        if (!hints.empty())
            e.addMessage("Or unknown aggregate function " + node.name + ". Maybe you meant: " + toString(hints));
        e.rethrow();
    }
    Names argument_names;
    DataTypes argument_types;
    bool arguments_present = true;