org.apache.hadoop.hive.ql.udf
Class UDFDate

java.lang.Object
  extended by org.apache.hadoop.hive.ql.exec.UDF
      extended by org.apache.hadoop.hive.ql.udf.UDFDate

public class UDFDate
extends UDF

UDFDate.


Constructor Summary
UDFDate()
           
 
Method Summary
 Text evaluate(Text dateString)
          Get the date part of a date time string.
 Text evaluate(TimestampWritable i)
           
 
Methods inherited from class org.apache.hadoop.hive.ql.exec.UDF
getRequiredFiles, getRequiredJars, getResolver, setResolver
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

UDFDate

public UDFDate()
Method Detail

evaluate

public Text evaluate(Text dateString)
Get the date part of a date time string.

Parameters:
dateString - the date string in the format of "yyyy-MM-dd HH:mm:ss" or "yyyy-MM-dd".
Returns:
the date in the format of "yyyy-MM-dd".

evaluate

public Text evaluate(TimestampWritable i)


Copyright © 2012 The Apache Software Foundation