Stony Brook-specific DB2 connection information.
Free sign up is required for some of the links below.
Good on-line books. The first is very useful for Project 2, the second and third mostly for Project 3.
To use JDBC in your application, you must first download and install a DB2 JDBC driver, db2jcc.jar. You can find the instructions here.
Once downloaded, you must import the driver into Eclipse. If you are using an IDE other than Eclipse, check the documentation for that IDE. You might need to put the driver's folder in your CLASSPATH variable or import the driver analogously to how it is done in Eclipse.
To import db2jcc.jar, click on the Window menu in Eclipse and select Preferences. In the resulting dialog box, choose Java then Buid Path then User Libraries. Click on New and define a library name, e.g., DB2LIBS. Then click Add JARs, navigate to the folder that contains db2jcc.jar and add the driver to the library.
Also add db2jcc.jar to tomcat's lib folder to enable the servlet to access the database.
To run your application, you would need to install Tomcat on your machine. The easiest way to debug and run your application is to install the Eclipse Tomcat plugin.