title: JBOSS deployment having HibernateException on oracle major version 11
body: <p>Trying to deploy application ear file with following settings in JBoss-4.2.3.GA</p>
  
  <p><strong>jboss-app.xml</strong></p>
  
  <pre><code>&lt;jboss-app&gt;
      &lt;loader-repository&gt;
          com.xxxx.xxx:loader=&lt;ear-name&gt;
        &lt;loader-repository-config&gt;
          java2ParentDelegation=false
        &lt;/loader-repository-config&gt;  
      &lt;/loader-repository&gt;
  &lt;/jboss-app&gt;
  </code></pre>
  
  <p><strong>persistence.xml</strong> (just a snippet)</p>
  
  <pre><code>&lt;property name="hibernate.dialect" value="org.hibernate.dialect.Oracle10gDialect"/&gt;
  &lt;property name="hibernate.hbm2ddl.auto" value="validate"/&gt;
  &lt;property name="hibernate.show_sql" value="false"/&gt;
  &lt;property name="hibernate.format_sql" value="false"/&gt;
  &lt;property name="jboss.entity.manager.factory.jndi.name" value="java:/XXXXFactory"/&gt;
  </code></pre>
  
  <p><strong>Got following logger info during deployment, I am not sure why an exception is listed in an INFO logger, can I not bother about this?</strong></p>
  
  <pre><code>16:30:07,239 INFO  [STDOUT] 16:30:07,238 INFO  [SettingsFactory] JDBC driver: Oracle JDBC driver, version: 11.2.0.3.0
  javax.ejb.EJBException: org.hibernate.HibernateException: unknown Oracle major version [11]
      at org.jboss.ejb3.tx.Ejb3TxPolicy.handleExceptionInOurTx(Ejb3TxPolicy.java:63)
      at org.jboss.aspects.tx.TxPolicy.invokeInOurTx(TxPolicy.java:83)
  
  
  Caused by: org.hibernate.HibernateException: unknown Oracle major version [11]
      at org.hibernate.dialect.DialectFactory$1.getDialectClass(DialectFactory.java:135)
      at org.hibernate.dialect.DialectFactory.determineDialect(DialectFactory.java:65)
      at org.hibernate.dialect.DialectFactory.buildDialect(DialectFactory.java:39)
      at org.hibernate.cfg.SettingsFactory.determineDialect(SettingsFactory.java:426)
  </code></pre>
  
  <p><strong>Note: We are using JBoss-Seam-2.2.0.GA</strong></p>
  
  <p><strong>Tried: <a href="https://stackoverflow.com/a/1158045/150371">this</a>, <a href="http://jaitechwriteups.blogspot.com/2008/08/how-to-upgrade-hibernate-in-jboss.html" rel="nofollow noreferrer">this</a> and <a href="http://smooth-java.blogspot.com/2011/08/fixing-problem-in-hibernate-unknown.html" rel="nofollow noreferrer">that</a></strong></p>
  
  <p>Please let me know if any additional information is required, I am trying to pull back the libs available in jboss to the ear.</p>
  
  <p><strong>Update: Tries</strong></p>
  
  <ol>
  <li>Figured out that the application is using 2 different sessions and<br>
  there is one hibernate.cfg.xml also for another legacy code, there
  is    no dialect specified in it. </li>
  <li>So added Oracle10g dialect to
  cfg.xml, it    stopped throwing above mentioned unknown oracle
  version error, but it    exceptioned as it couldn't load the
  10gDialect.</li>
  <li>Beauty is both the sessions are pointing to the same datasource.</li>
  </ol>