Skip to content
Closed
Changes from 1 commit
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
Prev Previous commit
Next Next commit
move radn with seed down
  • Loading branch information
brkyvz committed Apr 30, 2015
commit b4537165181679795ab3a8cc568fccfe79773108
Original file line number Diff line number Diff line change
Expand Up @@ -1245,8 +1245,8 @@ https://cwiki.apache.org/confluence/display/Hive/Enhanced+Aggregation%2C+Cube%2C
/* Other functions */
case Token("TOK_FUNCTION", Token(ARRAY(), Nil) :: children) =>
CreateArray(children.map(nodeToExpr))
case Token("TOK_FUNCTION", Token(RAND(seed), Nil) :: Nil) => Rand(seed.toLong)
case Token("TOK_FUNCTION", Token(RAND(), Nil) :: Nil) => Rand(Utils.random.nextLong())
case Token("TOK_FUNCTION", Token(RAND(seed), Nil) :: Nil) => Rand(seed.toLong)
case Token("TOK_FUNCTION", Token(SUBSTR(), Nil) :: string :: pos :: Nil) =>
Substring(nodeToExpr(string), nodeToExpr(pos), Literal.create(Integer.MAX_VALUE, IntegerType))
case Token("TOK_FUNCTION", Token(SUBSTR(), Nil) :: string :: pos :: length :: Nil) =>
Expand Down