title: Cannot create PoolableConnectionFactory (Unexpected throwable caught java.lang.StringIndexOutOfBoundsException: String index out of range: 11)
body: <p>I am using below statement for database in tomcat context.xml. Some time it works fine mainly when I restart my machine...but many time it give me Connection pool error</p>
  
  <pre><code>&lt;Resource name="jdbc/nits" auth="Container" type="javax.sql.DataSource"
                 maxActive="100" maxIdle="30" maxWait="10000"
                 username="@xxxxx" password="xxxxx" driverClassName="com.ibm.db2.jcc.DB2Driver"
                 url="jdbc:db2:DB0" defaultAutoCommit="false"/&gt;
  </code></pre>
  
  <blockquote>
    <p>Caused by: com.ibm.db2.jcc.c.SqlException: Unexpected throwable caught
    java.lang.StringIndexOutOfBoundsException: String index out of range:
    11    at com.ibm.db2.jcc.uw.UWConnection.a(UWConnection.java:484)     at
    com.ibm.db2.jcc.uw.UWConnection.(UWConnection.java:248)     at
    com.ibm.db2.jcc.DB2Driver.connect(DB2Driver.java:236)     at
    org.apache.tomcat.dbcp.dbcp.DriverConnectionFactory.createConnection(DriverConnectionFactory.java:38)
      at
    org.apache.tomcat.dbcp.dbcp.PoolableConnectionFactory.makeObject(PoolableConnectionFactory.java:294)
      at
    org.apache.tomcat.dbcp.dbcp.BasicDataSource.validateConnectionFactory(BasicDataSource.java:1247)
      at
    org.apache.tomcat.dbcp.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:1221)
      ... 80 more</p>
  </blockquote>
  
  <p>I tried the complete URL as well in statement after that it say Security Mechanism not supported. I am using DB2Jcc.jar. Please help me resolving this issue :(</p>