Author: jolee
Date: 2011-12-12 16:37:05 -0500 (Mon, 12 Dec 2011)
New Revision: 3733
Modified:
branches/7.1.x/hibernate-dialect/src/main/java/org/teiid/dialect/TeiidDialect.java
Log:
SOA-3434 TeiidDialect for Hibernate does not include a function to get the month value of
a date object.
Modified:
branches/7.1.x/hibernate-dialect/src/main/java/org/teiid/dialect/TeiidDialect.java
===================================================================
---
branches/7.1.x/hibernate-dialect/src/main/java/org/teiid/dialect/TeiidDialect.java 2011-12-12
21:29:14 UTC (rev 3732)
+++
branches/7.1.x/hibernate-dialect/src/main/java/org/teiid/dialect/TeiidDialect.java 2011-12-12
21:37:05 UTC (rev 3733)
@@ -125,6 +125,7 @@
registerFunction("formattimestamp", new
StandardSQLFunction("formattimestamp", Hibernate.STRING)); //$NON-NLS-1$
//$NON-NLS-2$
registerFunction("hour", new StandardSQLFunction("hour",
Hibernate.INTEGER)); //$NON-NLS-1$ //$NON-NLS-2$
registerFunction("minute", new StandardSQLFunction("minute",
Hibernate.INTEGER)); //$NON-NLS-1$ //$NON-NLS-2$
+ registerFunction("month", new StandardSQLFunction("month",
Hibernate.INTEGER)); //$NON-NLS-1$ //$NON-NLS-2$
registerFunction("monthname", new
StandardSQLFunction("monthname", Hibernate.STRING)); //$NON-NLS-1$
//$NON-NLS-2$
registerFunction("parsedate", new
StandardSQLFunction("parsedate", Hibernate.DATE)); //$NON-NLS-1$ //$NON-NLS-2$
registerFunction("parsetime", new
StandardSQLFunction("parsetime", Hibernate.TIME)); //$NON-NLS-1$ //$NON-NLS-2$
@@ -137,6 +138,8 @@
registerFunction("year", new StandardSQLFunction("year",
Hibernate.INTEGER)); //$NON-NLS-1$ //$NON-NLS-2$
registerFunction("modifytimezone", new
StandardSQLFunction("modifytimezone", Hibernate.TIMESTAMP)); //$NON-NLS-1$
//$NON-NLS-2$
+ registerFunction("array_get", new
StandardSQLFunction("array_get", Hibernate.OBJECT)); //$NON-NLS-1$
//$NON-NLS-2$
+ registerFunction("array_length", new
StandardSQLFunction("array_length", Hibernate.INTEGER)); //$NON-NLS-1$
//$NON-NLS-2$
registerFunction("convert", new
StandardSQLFunction("convert")); //$NON-NLS-1$ //$NON-NLS-2$
}
Show replies by date