1. How to get database version through Hibernate? stackoverflow.comIs there a way to get some information of the underlying database version through the Hibernate 3.2 API? I failed to find relevant bits both here and the javadoc. |
2. version where SQL type = DATE and java type = sql.Timestamp forum.hibernate.orgHi- I'm using Hibernate 2.1.3 and having some wierd behavior when trying to use a version/timestamp for optimistic locking. JDK 1.4, OracleDialect. I prevoiusly had the column mapped as a simple property, and everything worked fine. The SQL datatype of the Version column is DATE, and the java type of the version is java.sql.Timestamp. So my first attempt was to use ... |
3. HQL version of this one-line SQL statement forum.hibernate.orgPlease can someone here help? This is all I need converted from SQL to HQL: SELECT TOP 1 [fieldName] FROM [tableName] ORDER BY [fieldName] DESC I have actually tried to figure it out on my own but am getting stuck on how to implement "SELECT TOP" and "DESC" in HQL. It returns the largest number of a certain field within a ... |