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

Public Member Functions

 PgDateTrunc ()
 
RelDataType inferReturnType (SqlOperatorBinding opBinding)
 

Detailed Description

Definition at line 603 of file HeavyDBSqlOperatorTable.java.

Constructor & Destructor Documentation

com.mapd.calcite.parser.HeavyDBSqlOperatorTable.PgDateTrunc.PgDateTrunc ( )
inline

Definition at line 604 of file HeavyDBSqlOperatorTable.java.

604  {
605  super("PG_DATE_TRUNC",
606  SqlKind.OTHER_FUNCTION,
607  null,
608  null,
609  OperandTypes.family(SqlTypeFamily.STRING, SqlTypeFamily.DATETIME),
610  SqlFunctionCategory.SYSTEM);
611  }

Member Function Documentation

RelDataType com.mapd.calcite.parser.HeavyDBSqlOperatorTable.PgDateTrunc.inferReturnType ( SqlOperatorBinding  opBinding)
inline

Definition at line 614 of file HeavyDBSqlOperatorTable.java.

614  {
615  final RelDataTypeFactory typeFactory = opBinding.getTypeFactory();
616  return typeFactory.createTypeWithNullability(
617  typeFactory.createSqlType(
618  SqlTypeName.TIMESTAMP, opBinding.getOperandType(1).getPrecision()),
619  opBinding.getOperandType(1).isNullable());
620  }

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