2018-11-28 11:37:12 +00:00
|
|
|
#include <Dictionaries/CacheDictionary.h>
|
|
|
|
#include <Dictionaries/CacheDictionary.inc.h>
|
|
|
|
|
|
|
|
namespace DB
|
|
|
|
{
|
|
|
|
namespace ErrorCodes
|
|
|
|
{
|
|
|
|
extern const int TYPE_MISMATCH;
|
|
|
|
}
|
|
|
|
|
|
|
|
using TYPE = @NAME@;
|
|
|
|
void CacheDictionary::get@NAME@(const std::string & attribute_name, const PaddedPODArray<Key> & ids, const TYPE def, ResultArrayType<TYPE> & out) const
|
|
|
|
{
|
|
|
|
auto & attribute = getAttribute(attribute_name);
|
2019-08-03 11:02:40 +00:00
|
|
|
checkAttributeType(name, attribute_name, attribute.type, AttributeUnderlyingType::ut@NAME@);
|
2018-11-28 11:37:12 +00:00
|
|
|
|
2019-05-28 19:30:01 +00:00
|
|
|
getItemsNumberImpl<TYPE, TYPE>(attribute, ids, out, [&](const size_t) { return def; });
|
2018-11-28 11:37:12 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
}
|