Skip to content

Commit

Permalink
[VL] Enable arrays_overlap function (apache#5878)
Browse files Browse the repository at this point in the history
[VL] Enable arrays_overlap function.
  • Loading branch information
zhli1142015 authored May 27, 2024
1 parent 48e05f7 commit 95096e3
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1037,4 +1037,20 @@ class ScalarFunctionsValidateSuite extends FunctionsValidateTest {
}
}
}

test("arrays_overlap") {
withTempPath {
path =>
Seq[(Seq[Integer], Seq[Integer])]((Seq(1, 2, 3), Seq(3, 4)), (Seq(5, null), Seq()))
.toDF("v1", "v2")
.write
.parquet(path.getCanonicalPath)

spark.read.parquet(path.getCanonicalPath).createOrReplaceTempView("array_tbl")

runQueryAndCompare("select arrays_overlap(v1, v2) from array_tbl;") {
checkGlutenOperatorMatch[ProjectExecTransformer]
}
}
}
}
1 change: 0 additions & 1 deletion cpp/velox/substrait/SubstraitToVeloxPlanValidator.cc
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,6 @@ static const std::unordered_set<std::string> kBlackList = {
"repeat",
"trunc",
"sequence",
"arrays_overlap",
"approx_percentile",
"get_array_struct_fields"};

Expand Down
2 changes: 1 addition & 1 deletion docs/velox-backend-support-progress.md
Original file line number Diff line number Diff line change
Expand Up @@ -272,7 +272,7 @@ Gluten supports 199 functions. (Drag to right to see all data types)
| array_repeat | | | S | | S | S | S | S | S | S | S | S | S | S | S | | | | | | | |
| array_sort | array_sort | array_sort | S | | | | | | | | | | | | | | | | | | | |
| array_union | | | | | | | | | | | | | | | | | | | | | | |
| arrays_overlap | array_overlap | | | | | | | | | | | | | | | | | | | | | |
| arrays_overlap | array_overlap | S | | | | | | | | | | | | | | | | | | | | |
| arrays_zip | zip | | S | | | | | | | | | | | | | | | | | | | |
| cardinality | cardinality | | | | | | | | | | | | | | | | | | | | | |
| element_at | element_at | element_at | S | | | | | | | | | | | | | | | | S | S | | |
Expand Down

0 comments on commit 95096e3

Please sign in to comment.