Results 1 to 3 of 3

Thread: How to install the JDBC driver

  1. #1
    Join Date
    Apr 2009
    Posts
    49

    How to install the JDBC driver

    Hello,

    I had downloaded and installed the "SQL Server Management Studio Express" on my home PC.
    I connect with:
    server name: ESA-SAV01 \ sqlexpress
    Authentication: Windows Authentication

    So without a password.
    I can connect, create tables etc.....

    I coded a small java program to connect to the SQL database using JDBC with Java.

    In "Administrative Tools" / "Data Sources (ODBC)" then in "User Data Source" I click on the add button, then on the "Create New Data Source", I see at the end "SQL server",and there I click on SQL Server.
    Then a new window opens. There I met a name like "MyDataSource" for the name. In Server and I see "ESA-SAV01" or Local if I click on one or the other,another window opens and then I check with windows NT authentication for the network login ID after some try, I get the message that tells me that SQL Server does not exist.
    even if I click on another option.

    Why?

  2. #2
    Join Date
    Apr 2008
    Posts
    193

    Re: How to install the JDBC driver

    I have checked and am saying that in the version 3.2, all the JARS present in the %TOMCAT_HOME%/lib directory are automatically appended to Tomcat's classpath, but only the jars are appended. and if you wanted to append a ZIP file you will have to rename it to *.jar ( as a jar is only a renamed zip )

    With the two other options you could achieve this:

    Put the jar file in your webapplications WEB-INF/lib/ directory. But keep in mind that this set of JARs will only be added to the classpath for your webapplication only.Note if a different driver for the same JDBC URL is already available then the system classpath, then it may happen that it would be loaded instead of earlier one.

    You may change the Tomcat CLASSPATH environment variable, or else you could "-classpath" command-line option, to contain your JAR or ZIP. This is set in the Tomcat startup script, tomcat.bat/tomcat.sh.

  3. #3
    Join Date
    Dec 2008
    Posts
    202

    Re: How to install the JDBC driver

    Download the following files such as db2jcc.jar and db2jcc_license_cu.jar in order to make your apps talk to DB2 database – It is also available at IBM web site.

    Once you have downloaded these files keep those files in your local lib folder under your application root folder -- i.e you will be having a lib folder under WEB-INF folder so put these two files in it.

    The command to run on command prompt is CLASSPATH = /appRoot/WEB-INF/lib or add this line to your .bashrc file.You can try with this class Class.forName("COM.ibm.db2.jcc.DB2Driver"); instead of Class.forName("COM.ibm.db2.jdbc.app.DB2Driver"); Proper installation will Install the JDBC driver files.

Similar Threads

  1. JDBC Driver for Open Office Base
    By Rivan in forum Software Development
    Replies: 5
    Last Post: 21-07-2010, 05:18 AM
  2. How to install the DB2 JDBC driver with Jython
    By Liliana in forum Software Development
    Replies: 4
    Last Post: 21-02-2010, 04:19 AM
  3. Types of different JDBC driver in JAVA technology
    By GunFighter in forum Software Development
    Replies: 3
    Last Post: 11-09-2009, 02:11 PM
  4. How to use Transaction Management in JDBC
    By VinFanatic in forum Software Development
    Replies: 3
    Last Post: 25-04-2009, 12:39 PM
  5. How JSP call JDBC database connection
    By Swetlano in forum Software Development
    Replies: 3
    Last Post: 28-02-2009, 01:46 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Page generated in 1,713,489,788.80893 seconds with 17 queries