Skip to content

Commit 1a8d949

Browse files
committed
[SPARK-16282][SQL] Follow-up: remove "percentile" from temp function detection after implementing it natively
1 parent 2e80990 commit 1a8d949

File tree

2 files changed

+1
-5
lines changed

2 files changed

+1
-5
lines changed

sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/catalog/SessionCatalog.scala

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -939,10 +939,7 @@ class SessionCatalog(
939939
*/
940940
def isTemporaryFunction(name: FunctionIdentifier): Boolean = {
941941
// copied from HiveSessionCatalog
942-
val hiveFunctions = Seq(
943-
"hash",
944-
"histogram_numeric",
945-
"percentile")
942+
val hiveFunctions = Seq("histogram_numeric")
946943

947944
// A temporary function is a function that has been registered in functionRegistry
948945
// without a database name, and is neither a built-in function nor a Hive function

sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/catalog/SessionCatalogSuite.scala

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -981,7 +981,6 @@ class SessionCatalogSuite extends SparkFunSuite {
981981
assert(FunctionRegistry.builtin.functionExists("sum"))
982982
assert(!sessionCatalog.isTemporaryFunction(FunctionIdentifier("sum")))
983983
assert(!sessionCatalog.isTemporaryFunction(FunctionIdentifier("histogram_numeric")))
984-
assert(!sessionCatalog.isTemporaryFunction(FunctionIdentifier("percentile")))
985984
}
986985

987986
test("drop function") {

0 commit comments

Comments
 (0)