Skip to content

Commit

Permalink
Fix SqlParser Warning.
Browse files Browse the repository at this point in the history
  • Loading branch information
yhuai committed Jul 22, 2015
1 parent c03299a commit 25f5f36
Showing 1 changed file with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -271,8 +271,7 @@ class SqlParser extends AbstractSparkSQLParser with DataTypeParser {
lexical.normalizeKeyword(udfName) match {
case "sum" => SumDistinct(exprs.head)
case "count" => CountDistinct(exprs)
case name => UnresolvedFunction(name, exprs, isDistinct = true)
case _ => throw new AnalysisException(s"function $udfName does not support DISTINCT")
case _ => UnresolvedFunction(udfName, exprs, isDistinct = true)
}
}
| APPROXIMATE ~> ident ~ ("(" ~ DISTINCT ~> expression <~ ")") ^^ { case udfName ~ exp =>
Expand Down

0 comments on commit 25f5f36

Please sign in to comment.