title: How to get java.sql.Connection object from Hibernate Session
body: <p>I have requirement where I need <code>java.sql.Connection</code>. But I am using Hibernate here. Somehow I researched and I found below alternative but that's not working.</p>
  
  <pre><code>import org.hibernate.connection.ProxoolConnectionProvider;
  public class ConnectionDB{
      //I have imported below class 
      ProxoolConnectionProvider proxoolProvider = new ProxoolConnectionProvider();
      org.hibernate.cfg.Configuration cfg = HibernateUtil.getConfiguration();//this method will return configuration 
      java.util.Properties props =  cfg.getProperties();//This will return Properties Object
      //Using properties object I just tried to get The Connection Object by following method
      proxoolConn.configure(props);// I just configured the Porperties object 
      proxoolConn.getConnection();
  }
  </code></pre>
  
  <p>But no luck I just end-up with no exception in console .. I am using Struts 2, Hibernate and JasperReports.</p>
  
  <p>Can any one help me to get the connection object from Hibernate?</p>