Cant connect to SQL server with jtds 1.2.2
What i did was to add
commons-dbcp-1.2.2.jar
commons-pool-1.4.jar
commons-collections-3.2.1.jar - already added initially
to the class path of the application and tomcat
and add factory="org.apache.commons.dbcp.BasicDataSourceFactory" as can be seen below
to the context.
I got the solution thanks to the 2 topics below
http://www.coderanch.com/t/87782/Tomcat/One-resources-defined-context-xml#470239
http://forums.sun.com/thread.jspa?threadID=635640
commons-dbcp-1.2.2.jar
commons-pool-1.4.jar
commons-collections-3.2.1.jar - already added initially
to the class path of the application and tomcat
and add factory="org.apache.commons.dbcp.BasicDataSourceFactory" as can be seen below
- <Resource name="jdbc/PooledDS2" auth="Container" type="javax.sql.DataSource"
- factory="org.apache.commons.dbcp.BasicDataSourceFactory"
- maxActive="100" maxIdle="30" maxWait="10000"
- username="***" password="***" driverClassName="net.sourceforge.jtds.jdbc.Driver"
- url="jdbc:jtds:sqlserver://<>:1433/<>"/>
to the context.
I got the solution thanks to the 2 topics below
http://www.coderanch.com/t/87782/Tomcat/One-resources-defined-context-xml#470239
http://forums.sun.com/thread.jspa?threadID=635640