We are trying to use sybase function “power” to do mathematical calculation for one of the DB columns.
The hibernate is generating power function as
pow(?, xyzo0_.AmtScale)
whereas sybase supports power function as Syntax
POWER( numeric-expression-1, numeric-expression-2 )
We have tried modifying the hibernate.dialect. Have tried
org.hibernate.dialect.SybaseASE15Dialect
org.hibernate.dialect.Sybase11Dialect
org.hibernate.dialect.SybaseAnywhereDialect
but all dialects generate the power function as
pow(?, xyzo0_.AmtScale).
Is this hibernate issue or are we missing something?
Fixed this. We added custom implementation by extending the Sybase Dialect class.
In this class constructor, we have called the registerFunction to specify alternative to power function.