// Licensed to the Apache Software Foundation (ASF) under one // or more contributor license agreements. See the NOTICE file // distributed with this work for additional information // regarding copyright ownership. The ASF licenses this file // to you under the Apache License, Version 2.0 (the // "License"); you may not use this file except in compliance // with the License. You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, // software distributed under the License is distributed on an // "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. #pragma once #include #include #include "http/http_status.h" #include "vec/aggregate_functions/aggregate_function.h" #include "vec/columns/column_complex.h" #include "vec/columns/columns_number.h" #include "vec/data_types/data_type.h" #include "vec/functions/function.h" #define NUMERIC_TYPE_TO_COLUMN_TYPE(M) \ M(UInt8, ColumnUInt8) \ M(Int8, ColumnInt8) \ M(Int16, ColumnInt16) \ M(Int32, ColumnInt32) \ M(Int64, ColumnInt64) \ M(Int128, ColumnInt128) \ M(Float32, ColumnFloat32) \ M(Float64, ColumnFloat64) #define DECIMAL_TYPE_TO_COLUMN_TYPE(M) \ M(Decimal32, ColumnDecimal) \ M(Decimal64, ColumnDecimal) \ M(Decimal128, ColumnDecimal) \ M(Decimal128I, ColumnDecimal) #define STRING_TYPE_TO_COLUMN_TYPE(M) \ M(String, ColumnString) \ M(JSONB, ColumnString) #define TIME_TYPE_TO_COLUMN_TYPE(M) \ M(Date, ColumnInt64) \ M(DateTime, ColumnInt64) \ M(DateV2, ColumnUInt32) \ M(DateTimeV2, ColumnUInt64) #define COMPLEX_TYPE_TO_COLUMN_TYPE(M) \ M(BitMap, ColumnBitmap) \ M(HLL, ColumnHLL) #define TYPE_TO_BASIC_COLUMN_TYPE(M) \ NUMERIC_TYPE_TO_COLUMN_TYPE(M) \ DECIMAL_TYPE_TO_COLUMN_TYPE(M) \ STRING_TYPE_TO_COLUMN_TYPE(M) \ TIME_TYPE_TO_COLUMN_TYPE(M) #define TYPE_TO_COLUMN_TYPE(M) \ TYPE_TO_BASIC_COLUMN_TYPE(M) \ COMPLEX_TYPE_TO_COLUMN_TYPE(M) namespace doris::vectorized { template