DZone Snippets is a public source code repository. Easily build up your personal collection of code snippets, categorize them with tags / keywords, and share them with the world

Thomas has posted 33 posts at DZone. View Full User Profile

Hibernate Oracle Dialect With XMLType Support

10.12.2011
| 5097 views |
  • submit to reddit
        
package your.package;

import org.hibernate.dialect.Oracle10gDialect;

public class OracleDialectWithXmlSupport extends Oracle10gDialect {

   public OracleDialectWithXmlSupport() {
      super();
      registerHibernateType(oracle.xdb.XMLType._SQL_TYPECODE, "xmltype");
      registerColumnType(oracle.xdb.XMLType._SQL_TYPECODE, "xmltype");
   }
}