Package | Description |
---|---|
org.apache.hadoop.hive.contrib.genericudf.example | |
org.apache.hadoop.hive.ql.exec |
Hive QL execution tasks, operators, functions and other handlers.
|
org.apache.hadoop.hive.ql.optimizer.calcite.translator | |
org.apache.hadoop.hive.ql.parse | |
org.apache.hadoop.hive.ql.plan | |
org.apache.hadoop.hive.ql.udf.generic |
Standard toolkit and framework for generic User-defined functions.
|
org.apache.hadoop.hive.ql.udf.xml |
Modifier and Type | Class and Description |
---|---|
class |
GenericUDFDBOutput
GenericUDFDBOutput is designed to output data directly from Hive to a JDBC
datastore.
|
Modifier and Type | Method and Description |
---|---|
static GenericUDF |
FunctionRegistry.cloneGenericUDF(GenericUDF genericUDF)
Create a copy of an existing GenericUDF.
|
GenericUDF |
FunctionInfo.getGenericUDF()
Get a new GenericUDF object for the function.
|
static GenericUDF |
FunctionRegistry.getGenericUDFForAnd()
A shortcut to get the "and" GenericUDF.
|
static GenericUDF |
FunctionRegistry.getGenericUDFForIndex()
A shortcut to get the "index" GenericUDF.
|
Modifier and Type | Method and Description |
---|---|
static GenericUDF |
FunctionRegistry.cloneGenericUDF(GenericUDF genericUDF)
Create a copy of an existing GenericUDF.
|
static boolean |
FunctionRegistry.isDeterministic(GenericUDF genericUDF)
Returns whether a GenericUDF is deterministic or not.
|
static boolean |
FunctionRegistry.isOpCast(GenericUDF genericUDF) |
static boolean |
FunctionRegistry.isStateful(GenericUDF genericUDF)
Returns whether a GenericUDF is stateful or not.
|
Modifier and Type | Method and Description |
---|---|
FunctionInfo |
Registry.registerGenericUDF(String functionName,
Class<? extends GenericUDF> genericUDFClass,
FunctionInfo.FunctionResource... resources) |
Constructor and Description |
---|
FunctionInfo(boolean isNative,
String displayName,
GenericUDF genericUDF,
FunctionInfo.FunctionResource... resources) |
Modifier and Type | Method and Description |
---|---|
static GenericUDF |
SqlFunctionConverter.getHiveUDF(org.apache.calcite.sql.SqlOperator op,
org.apache.calcite.rel.type.RelDataType dt,
int argsLength) |
Modifier and Type | Method and Description |
---|---|
static org.apache.calcite.sql.SqlOperator |
SqlFunctionConverter.getCalciteOperator(String funcTextName,
GenericUDF hiveUDF,
com.google.common.collect.ImmutableList<org.apache.calcite.rel.type.RelDataType> calciteArgTypes,
org.apache.calcite.rel.type.RelDataType retType) |
protected void |
JoinCondTypeCheckProcFactory.JoinCondDefaultExprProcessor.validateUDF(ASTNode expr,
boolean isFunction,
TypeCheckCtx ctx,
FunctionInfo fi,
List<ExprNodeDesc> children,
GenericUDF genericUDF) |
Modifier and Type | Method and Description |
---|---|
protected void |
TypeCheckProcFactory.DefaultExprProcessor.validateUDF(ASTNode expr,
boolean isFunction,
TypeCheckCtx ctx,
FunctionInfo fi,
List<ExprNodeDesc> children,
GenericUDF genericUDF) |
Modifier and Type | Method and Description |
---|---|
GenericUDF |
ExprNodeGenericFuncDesc.getGenericUDF() |
Modifier and Type | Method and Description |
---|---|
static ExprNodeGenericFuncDesc |
ExprNodeGenericFuncDesc.newInstance(GenericUDF genericUDF,
List<ExprNodeDesc> children) |
static ExprNodeGenericFuncDesc |
ExprNodeGenericFuncDesc.newInstance(GenericUDF genericUDF,
String funcText,
List<ExprNodeDesc> children)
Create a ExprNodeGenericFuncDesc based on the genericUDFClass and the
children parameters.
|
void |
ExprNodeGenericFuncDesc.setGenericUDF(GenericUDF genericUDF) |
Constructor and Description |
---|
ExprNodeGenericFuncDesc(ObjectInspector oi,
GenericUDF genericUDF,
List<ExprNodeDesc> children) |
ExprNodeGenericFuncDesc(ObjectInspector oi,
GenericUDF genericUDF,
String funcText,
List<ExprNodeDesc> children) |
ExprNodeGenericFuncDesc(TypeInfo typeInfo,
GenericUDF genericUDF,
List<ExprNodeDesc> children) |
ExprNodeGenericFuncDesc(TypeInfo typeInfo,
GenericUDF genericUDF,
String funcText,
List<ExprNodeDesc> children) |
Modifier and Type | Class and Description |
---|---|
class |
AbstractGenericUDFEWAHBitmapBop
An abstract class for a UDF that performs a binary operation between two EWAH-compressed bitmaps.
|
class |
AbstractGenericUDFReflect
common class for reflective UDFs
|
class |
GenericUDFAbs
GenericUDFAbs.
|
class |
GenericUDFAddMonths
GenericUDFAddMonths.
|
class |
GenericUDFArray
GenericUDFArray.
|
class |
GenericUDFArrayContains
GenericUDFArrayContains.
|
class |
GenericUDFAssertTrue
GenericUDFAssertTrue
|
class |
GenericUDFBaseArithmetic
Wrapper UDF that will instantiate the proper arithmetic UDF (numeric, date, etc)
depending on the argument types
|
class |
GenericUDFBaseBinary
Base class for binary operators, overrides getDisplayString()
|
class |
GenericUDFBaseCompare
GenericUDF Base Class for operations.
|
class |
GenericUDFBaseDTI |
class |
GenericUDFBaseNumeric
GenericUDF Base Class for operations.
|
class |
GenericUDFBasePad |
class |
GenericUDFBaseTrim |
class |
GenericUDFBaseUnary |
class |
GenericUDFBetween |
class |
GenericUDFBridge
GenericUDFBridge encapsulates UDF to provide the same interface as
GenericUDF.
|
class |
GenericUDFCase
GenericUDF Class for SQL construct "CASE a WHEN b THEN c [ELSE f] END".
|
class |
GenericUDFCbrt
GenericUDFCbrt.
|
class |
GenericUDFCeil |
class |
GenericUDFCoalesce
GenericUDF Class for SQL construct "COALESCE(a, b, c)".
|
class |
GenericUDFConcat
GenericUDFConcat.
|
class |
GenericUDFConcatWS
Generic UDF for string function
CONCAT_WS(sep, [string | array(string)]+) |
class |
GenericUDFCurrentDate |
class |
GenericUDFCurrentTimestamp |
class |
GenericUDFCurrentUser |
class |
GenericUDFDate
UDFDate.
|
class |
GenericUDFDateAdd
UDFDateAdd.
|
class |
GenericUDFDateDiff
UDFDateDiff.
|
class |
GenericUDFDateFormat
GenericUDFDateFormat.
|
class |
GenericUDFDateSub
UDFDateSub.
|
class |
GenericUDFDecode |
class |
GenericUDFElt
Generic UDF for string function
ELT(N,str1,str2,str3,...) . |
class |
GenericUDFEncode |
class |
GenericUDFEWAHBitmapAnd
GenericEWAHUDFBitmapAnd.
|
class |
GenericUDFEWAHBitmapEmpty |
class |
GenericUDFEWAHBitmapOr
GenericUDFEWAHBitmapOr.
|
class |
GenericUDFFactorial
GenericUDFFactorial
|
class |
GenericUDFField
GenericUDFField.
|
class |
GenericUDFFloor |
class |
GenericUDFFloorCeilBase |
class |
GenericUDFFormatNumber
Generic UDF for format_number function
FORMAT_NUMBER(X, D) . |
class |
GenericUDFFromUtcTimestamp |
class |
GenericUDFGreatest
GenericUDF Class for SQL construct "greatest(v1, v2, ..
|
class |
GenericUDFHash
GenericUDF Class for computing hash values.
|
class |
GenericUDFIf
IF(expr1,expr2,expr3)
If expr1 is TRUE (expr1 <> 0 and expr1 <> NULL) then IF() returns expr2; otherwise it returns expr3. |
class |
GenericUDFIn
GenericUDFIn
Example usage:
SELECT key FROM src WHERE key IN ("238", "1");
From MySQL page on IN(): To comply with the SQL standard, IN returns NULL
not only if the expression on the left hand side is NULL, but also if no
match is found in the list and one of the expressions in the list is NULL.
|
class |
GenericUDFIndex
GenericUDFIndex.
|
class |
GenericUDFInFile
IN_FILE(str, filename) returns true if 'str' appears in the file specified
by 'filename'.
|
class |
GenericUDFInitCap
UDFInitCap.
|
class |
GenericUDFInstr
Generic UDF for string function
INSTR(str,substr) . |
class |
GenericUDFLag |
class |
GenericUDFLastDay
GenericUDFLastDay.
|
class |
GenericUDFLead |
class |
GenericUDFLeadLag |
class |
GenericUDFLeast
GenericUDF Class for SQL construct "least(v1, v2, ..
|
class |
GenericUDFLevenshtein
GenericUDFLevenshtein.
|
class |
GenericUDFLocate
Generic UDF for string function
LOCATE(substr, str) ,
LOCATE(substr, str, start) . |
class |
GenericUDFLower
UDFLower.
|
class |
GenericUDFLpad
UDFLpad.
|
class |
GenericUDFLTrim
UDFLTrim.
|
class |
GenericUDFMacro
GenericUDFMacro wraps a user-defined macro expression into a GenericUDF
interface.
|
class |
GenericUDFMap
GenericUDFMap.
|
class |
GenericUDFMapKeys
GenericUDFMapKeys.
|
class |
GenericUDFMapValues
GenericUDFMapValues.
|
class |
GenericUDFMonthsBetween
UDFMonthsBetween.
|
class |
GenericUDFNamedStruct |
class |
GenericUDFNextDay
GenericUDFNextDay.
|
class |
GenericUDFNvl |
class |
GenericUDFOPAnd
GenericUDF Class for computing and.
|
class |
GenericUDFOPDivide
Note that in SQL, the return type of divide is not necessarily the same
as the parameters.
|
class |
GenericUDFOPDTIMinus |
class |
GenericUDFOPDTIPlus |
class |
GenericUDFOPEqual
GenericUDF Class for operation EQUAL.
|
class |
GenericUDFOPEqualNS |
class |
GenericUDFOPEqualOrGreaterThan
GenericUDF Class for operation EqualOrGreaterThan.
|
class |
GenericUDFOPEqualOrLessThan
GenericUDF Class for operation EqualOrLessThan.
|
class |
GenericUDFOPGreaterThan
GenericUDF Class for operation GreaterThan.
|
class |
GenericUDFOPLessThan
GenericUDF Class for operation LessThan.
|
class |
GenericUDFOPMinus |
class |
GenericUDFOPMod |
class |
GenericUDFOPMultiply |
class |
GenericUDFOPNegative |
class |
GenericUDFOPNot
GenericUDFOPNot.
|
class |
GenericUDFOPNotEqual
GenericUDF Class for operation Not EQUAL.
|
class |
GenericUDFOPNotNull
GenericUDFOPNotNull.
|
class |
GenericUDFOPNull
GenericUDFOPNull.
|
class |
GenericUDFOPNumericMinus |
class |
GenericUDFOPNumericPlus
The reason that we list evaluate methods with all numeric types is for both
better performance and type checking (so we know int + int is still an int
instead of a double); otherwise a single method that takes (Number a, Number
b) and use a.doubleValue() == b.doubleValue() is enough.
|
class |
GenericUDFOPOr
GenericUDF Class for computing or.
|
class |
GenericUDFOPPlus
The reason that we list evaluate methods with all numeric types is for both
better performance and type checking (so we know int + int is still an int
instead of a double); otherwise a single method that takes (Number a, Number
b) and use a.doubleValue() == b.doubleValue() is enough.
|
class |
GenericUDFOPPositive |
class |
GenericUDFPosMod
class for computing positive modulo.
|
class |
GenericUDFPower |
class |
GenericUDFPrintf
Generic UDF for printf function
printf(String format, Obj... |
class |
GenericUDFReflect
A simple generic udf to call java static functions via reflection.
|
class |
GenericUDFReflect2
A simple generic udf to call java functions via reflection.
|
class |
GenericUDFRound
Note: rounding function permits rounding off integer digits in decimal numbers, which essentially
downgrades the scale to negative territory.
|
class |
GenericUDFRpad
UDFRpad.
|
class |
GenericUDFRTrim
UDFRTrim.
|
class |
GenericUDFSentences
GenericUDFSentences: splits a natural language chunk of text into sentences and words.
|
class |
GenericUDFSize
GenericUDFSize.
|
class |
GenericUDFSortArray
Generic UDF for array sort
SORT_ARRAY(array(obj1, obj2, obj3...)) . |
class |
GenericUDFSoundex
GenericUDFSoundex.
|
class |
GenericUDFSplit
GenericUDFSplit.
|
class |
GenericUDFStringToMap
GenericUDFStringToMap.
|
class |
GenericUDFStruct |
class |
GenericUDFTimestamp
GenericUDFTimestamp
Example usage:
...
|
class |
GenericUDFToBinary |
class |
GenericUDFToChar |
class |
GenericUDFToDate
GenericUDFToDate
|
class |
GenericUDFToDecimal |
class |
GenericUDFToIntervalDayTime
GenericUDFIntervalDayTime
Example usage:
...
|
class |
GenericUDFToIntervalYearMonth
GenericUDFIntervalYearMonth
Example usage:
...
|
class |
GenericUDFToUnixTimeStamp
deterministic version of UDFUnixTimeStamp.
|
class |
GenericUDFToUtcTimestamp |
class |
GenericUDFToVarchar |
class |
GenericUDFTranslate
TRANSLATE(string input, string from, string to) is an equivalent function to translate in
PostGresSQL.
|
class |
GenericUDFTrim
UDFTrim.
|
class |
GenericUDFTrunc
GenericUDFTrunc.
|
class |
GenericUDFUnion |
class |
GenericUDFUnixTimeStamp |
class |
GenericUDFUpper
UDFUpper.
|
class |
GenericUDFWhen
GenericUDF Class for SQL construct
"CASE WHEN a THEN b WHEN c THEN d [ELSE f] END".
|
class |
UDFCurrentDB |
Modifier and Type | Method and Description |
---|---|
GenericUDF |
GenericUDFOPLessThan.flip() |
GenericUDF |
GenericUDFOPGreaterThan.flip() |
GenericUDF |
GenericUDFOPEqualOrLessThan.flip() |
GenericUDF |
GenericUDFOPEqualOrGreaterThan.flip() |
GenericUDF |
GenericUDF.flip()
Some functions like comparisons may be affected by appearing order of arguments.
|
protected GenericUDF |
GenericUDFOPPlus.instantiateDTIUDF() |
protected GenericUDF |
GenericUDFOPMinus.instantiateDTIUDF() |
protected abstract GenericUDF |
GenericUDFBaseArithmetic.instantiateDTIUDF()
Instantiate date-time/interval version of the arithmetic UDF
|
GenericUDF |
GenericUDFOPOr.negative() |
GenericUDF |
GenericUDFOPNull.negative() |
GenericUDF |
GenericUDFOPNotNull.negative() |
GenericUDF |
GenericUDFOPNotEqual.negative() |
GenericUDF |
GenericUDFOPLessThan.negative() |
GenericUDF |
GenericUDFOPGreaterThan.negative() |
GenericUDF |
GenericUDFOPEqualOrLessThan.negative() |
GenericUDF |
GenericUDFOPEqualOrGreaterThan.negative() |
GenericUDF |
GenericUDFOPEqual.negative() |
GenericUDF |
GenericUDFOPAnd.negative() |
GenericUDF |
GenericUDF.negative()
Gets the negative function of the current one.
|
Modifier and Type | Class and Description |
---|---|
class |
GenericUDFXPath |
Copyright © 2017 The Apache Software Foundation. All rights reserved.