MCPcopy Create free account
hub / github.com/apache/impala / WeekOfYear

Method WeekOfYear

be/src/exprs/date-functions-ir.cc:94–101  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

92}
93
94IntVal DateFunctions::WeekOfYear(FunctionContext* context, const DateVal& d_val) {
95 if (d_val.is_null) return IntVal::null();
96 DateValue dv = DateValue::FromDateVal(d_val);
97
98 int yweek = dv.Iso8601WeekOfYear();
99 if (yweek == -1) return IntVal::null();
100 return IntVal(yweek);
101}
102
103StringVal DateFunctions::LongDayName(FunctionContext* context, const DateVal& d_val) {
104 if (d_val.is_null) return StringVal::null();

Callers

nothing calls this directly

Calls 2

IntValClass · 0.85
Iso8601WeekOfYearMethod · 0.80

Tested by

no test coverage detected