OmniSciDB  85c2d10cdc
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
com.mapd.calcite.parser.MapDSqlOperatorTable.Datepart Class Reference
+ Inheritance diagram for com.mapd.calcite.parser.MapDSqlOperatorTable.Datepart:
+ Collaboration diagram for com.mapd.calcite.parser.MapDSqlOperatorTable.Datepart:

Public Member Functions

 Datepart ()
 
RelDataType inferReturnType (SqlOperatorBinding opBinding)
 

Detailed Description

Definition at line 477 of file MapDSqlOperatorTable.java.

Constructor & Destructor Documentation

com.mapd.calcite.parser.MapDSqlOperatorTable.Datepart.Datepart ( )
inline

Definition at line 478 of file MapDSqlOperatorTable.java.

478  {
479  super("DATEPART",
480  SqlKind.OTHER_FUNCTION,
481  null,
482  null,
483  OperandTypes.family(SqlTypeFamily.STRING, SqlTypeFamily.DATETIME),
484  SqlFunctionCategory.TIMEDATE);
485  }

Member Function Documentation

RelDataType com.mapd.calcite.parser.MapDSqlOperatorTable.Datepart.inferReturnType ( SqlOperatorBinding  opBinding)
inline

Definition at line 488 of file MapDSqlOperatorTable.java.

References BIGINT.

488  {
489  final RelDataTypeFactory typeFactory = opBinding.getTypeFactory();
490  return typeFactory.createTypeWithNullability(
491  typeFactory.createSqlType(SqlTypeName.BIGINT),
492  opBinding.getOperandType(1).isNullable());
493  }
#define BIGINT

The documentation for this class was generated from the following file: