use of org.apache.hadoop.hive.ql.udf.UDFWeekOfYear in project hive by apache.
the class TestVectorDateExpressions method compareToUDFWeekOfYearDate.
private void compareToUDFWeekOfYearDate(long t, int y) {
UDFWeekOfYear udf = new UDFWeekOfYear();
TimestampWritable tsw = toTimestampWritable(t);
IntWritable res = udf.evaluate(tsw);
Assert.assertEquals(res.get(), y);
}
use of org.apache.hadoop.hive.ql.udf.UDFWeekOfYear in project hive by apache.
the class TestVectorTimestampExpressions method compareToUDFWeekOfYearLong.
private void compareToUDFWeekOfYearLong(Timestamp t, int y) {
UDFWeekOfYear udf = new UDFWeekOfYear();
TimestampWritable tsw = new TimestampWritable(t);
IntWritable res = udf.evaluate(tsw);
Assert.assertEquals(res.get(), y);
}
Aggregations