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

Public Member Functions

 Datediff ()
 
RelDataType inferReturnType (SqlOperatorBinding opBinding)
 

Detailed Description

Definition at line 524 of file MapDSqlOperatorTable.java.

Constructor & Destructor Documentation

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

Definition at line 525 of file MapDSqlOperatorTable.java.

525  {
526  super("DATEDIFF",
527  SqlKind.OTHER_FUNCTION,
528  null,
529  null,
530  OperandTypes.family(SqlTypeFamily.STRING,
531  SqlTypeFamily.DATETIME,
532  SqlTypeFamily.DATETIME),
533  SqlFunctionCategory.TIMEDATE);
534  }

Member Function Documentation

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

Definition at line 537 of file MapDSqlOperatorTable.java.

References BIGINT.

537  {
538  final RelDataTypeFactory typeFactory = opBinding.getTypeFactory();
539  return typeFactory.createTypeWithNullability(
540  typeFactory.createSqlType(SqlTypeName.BIGINT),
541  opBinding.getOperandType(1).isNullable()
542  || opBinding.getOperandType(2).isNullable());
543  }
#define BIGINT

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