title: Cannot initialise HikariCP pooled connection, Failure in loading native library db2jcct2
body: <p>I'm trying to use <a href="https://github.com/brettwooldridge/HikariCP" rel="nofollow noreferrer">HikariCP</a> together with DB2 but get the following error:</p>
  
  <blockquote>
    <p>Failure in loading native library db2jcct2,
    java.lang.UnsatisfiedLinkError: db2jcct2</p>
  </blockquote>
  
  <p>I have db2jcc4.jar file at my class path and only it. 
  And the following hikari properties file:</p>
  
  <pre><code>dataSourceClassName=com.ibm.db2.jcc.DB2SimpleDataSource
  dataSource.user=username
  dataSource.password=password
  dataSource.databaseName=database
  dataSource.serverName=server:50000
  </code></pre>
  
  <p>From what I understand <a href="https://stackoverflow.com/questions/3957131/java-lang-unsatisfiedlinkerror-while-loading-db2-jdbc-driver">Hikari tries to use type 2 driver</a> and therefor it requires native library db2jcct2 is it right? And if yes, how can I say it implicitly to look for type 4 driver?</p>
  
  <p><strong>Update</strong>:
  Proposed answer doesn't solve my issue. It can give direction but I could't get the correct answer only by reading that answer. At the same time you can find the answer in the comments to this question. </p>