[refactor] Remove decimal v1 related code from code base (#6079)

remove ALL DECIMAL V1 type code , this is a part of #6073
This commit is contained in:
Zhengguo Yang
2021-07-07 10:26:32 +08:00
committed by GitHub
parent d6e6c7815b
commit 739c0268ff
151 changed files with 707 additions and 4369 deletions

View File

@ -635,14 +635,6 @@ bool EsScanNode::to_ext_literal(PrimitiveType slot_type, void* value, TExtLitera
break;
}
case TYPE_DECIMAL: {
node_type = (TExprNodeType::DECIMAL_LITERAL);
TDecimalLiteral decimal_literal;
decimal_literal.__set_value(reinterpret_cast<DecimalValue*>(value)->to_string());
literal->__set_decimal_literal(decimal_literal);
break;
}
case TYPE_DATE:
case TYPE_DATETIME: {
node_type = (TExprNodeType::DATE_LITERAL);
@ -861,15 +853,6 @@ Status EsScanNode::materialize_row(MemPool* tuple_pool, Tuple* tuple,
reinterpret_cast<DateTimeValue*>(slot)->set_type(TIME_DATETIME);
break;
}
case TYPE_DECIMAL: {
if (val_idx >= col.binary_vals.size()) {
return Status::InternalError(
strings::Substitute(ERROR_INVALID_COL_DATA, "DECIMAL"));
}
const string& val = col.binary_vals[val_idx];
*reinterpret_cast<DecimalValue*>(slot) = *reinterpret_cast<const DecimalValue*>(&val);
break;
}
default:
DCHECK(false);
}