Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 8 additions & 9 deletions be/src/exec/es_predicate.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -53,22 +53,22 @@ std::string ExtLiteral::value_to_string() {
std::stringstream ss;
switch (_type) {
case TYPE_TINYINT:
ss << (int)get_byte();
ss << std::to_string(get_byte());
break;
case TYPE_SMALLINT:
ss << get_short();
ss << std::to_string(get_short());
break;
case TYPE_INT:
ss << get_int();
ss << std::to_string(get_int());
break;
case TYPE_BIGINT:
ss << get_long();
ss << std::to_string(get_long());
break;
case TYPE_FLOAT:
ss << get_float();
ss << std::to_string(get_float());
break;
case TYPE_DOUBLE:
ss << get_double();
ss << std::to_string(get_double());
break;
case TYPE_CHAR:
case TYPE_VARCHAR:
Expand All @@ -79,7 +79,7 @@ std::string ExtLiteral::value_to_string() {
ss << get_date_string();
break;
case TYPE_BOOLEAN:
ss << get_bool();
ss << std::to_string(get_bool());
break;
case TYPE_DECIMAL:
ss << get_decimal_string();
Expand Down Expand Up @@ -332,10 +332,8 @@ bool EsPredicate::build_disjuncts_list(Expr* conjunct, vector<ExtPredicate*>& di
return false;
}

TExtInPredicate ext_in_predicate;
vector<ExtLiteral> in_pred_values;
InPredicate* pred = dynamic_cast<InPredicate*>(conjunct);
ext_in_predicate.__set_is_not_in(pred->is_not_in());
if (Expr::type_without_cast(pred->get_child(0)) != TExprNodeType::SLOT_REF) {
return false;
}
Expand Down Expand Up @@ -365,6 +363,7 @@ bool EsPredicate::build_disjuncts_list(Expr* conjunct, vector<ExtPredicate*>& di

ExtPredicate* predicate = new ExtInPredicate(
TExprNodeType::IN_PRED,
pred->is_not_in(),
slot_desc->col_name(),
slot_desc->type(),
in_pred_values);
Expand Down
6 changes: 4 additions & 2 deletions be/src/exec/es_predicate.h
Original file line number Diff line number Diff line change
Expand Up @@ -106,11 +106,12 @@ struct ExtBinaryPredicate : public ExtPredicate {
struct ExtInPredicate : public ExtPredicate {
ExtInPredicate(
TExprNodeType::type node_type,
bool is_not_in,
const std::string& name,
const TypeDescriptor& type,
const std::vector<ExtLiteral>& values) :
ExtPredicate(node_type),
is_not_in(false),
is_not_in(is_not_in),
col(name, type),
values(values) {
}
Expand Down Expand Up @@ -140,10 +141,11 @@ struct ExtIsNullPredicate : public ExtPredicate {
TExprNodeType::type node_type,
const std::string& name,
const TypeDescriptor& type,
bool is_not_null,
ExtLiteral value) :
ExtPredicate(node_type),
col(name, type),
is_not_null(false) {
is_not_null(is_not_null) {
}

ExtColumnDesc col;
Expand Down
2 changes: 1 addition & 1 deletion be/src/util/es_scan_reader.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ Status ESScanReader::open() {
long status = _network_client.get_http_status();
if (status != 200) {
std::stringstream ss;
ss << "invalid response http status for open: " << status;
ss << "invalid response http status for open: " << status << ", response:" << _cached_response;
LOG(WARNING) << ss.str();
return Status(ss.str());
}
Expand Down