Skip to content

Commit

Permalink
For comments.
Browse files Browse the repository at this point in the history
  • Loading branch information
viirya committed Jan 28, 2016
1 parent 7350f07 commit 7d31844
Showing 1 changed file with 5 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -224,15 +224,16 @@ https://cwiki.apache.org/confluence/display/Hive/Enhanced+Aggregation%2C+Cube%2C
case Nil =>
ShowFunctions(None, None)
case Token(name, Nil) :: Nil =>
ShowFunctions(None, Some(unquoteString(name)))
ShowFunctions(None, Some(unquoteString(cleanIdentifier(name))))
case Token(db, Nil) :: Token(name, Nil) :: Nil =>
ShowFunctions(Some(unquoteString(db)), Some(unquoteString(name)))
ShowFunctions(Some(unquoteString(cleanIdentifier(db))),
Some(unquoteString(cleanIdentifier(name))))
case _ =>
noParseRule("SHOW FUNCTIONS", node)
}

case Token("TOK_DESCFUNCTION", Token(functionName, Nil) :: isExtended) =>
DescribeFunction(functionName, isExtended.nonEmpty)
DescribeFunction(cleanIdentifier(functionName), isExtended.nonEmpty)

case Token("TOK_QUERY", queryArgs @ Token("TOK_CTE" | "TOK_FROM" | "TOK_INSERT", _) :: _) =>
val (fromClause: Option[ASTNode], insertClauses, cteRelations) =
Expand Down Expand Up @@ -613,7 +614,7 @@ https://cwiki.apache.org/confluence/display/Hive/Enhanced+Aggregation%2C+Cube%2C
noParseRule("Select", node)
}

protected val escapedIdentifier = "`([^`]+)`".r
protected val escapedIdentifier = "`(.+)`".r
protected val doubleQuotedString = "\"([^\"]+)\"".r
protected val singleQuotedString = "'([^']+)'".r

Expand Down

0 comments on commit 7d31844

Please sign in to comment.