Nov 05

A concise guide to setup Oracle database connection with Java/JSP

Scribbled on Monday, November 5th, 2007

Setting up “CLASSPATH” variable:

This is the last part of setting Environment Variables :)
i) Goto Tomcat lib directory, it will be like “D:tomcat-6.0.10-preconfiguredapache-tomcat-6.0.10lib”Note down the path to a text file

Append these three files names: ojdbc14.jar, servlet-api.jar, jsp-api.jar, el-api.jar

Like this:

“.;D:tomcat-6.0.10-preconfiguredapache-tomcat-6.0.10libojdbc14.jar;

D:tomcat-6.0.10-preconfiguredapache-tomcat-6.0.10libjsp-api.jar;

D:tomcat-6.0.10-preconfiguredapache-tomcat-6.0.10libservlet-api.jar;

D:tomcat-6.0.10-preconfiguredapache-tomcat-6.0.10libel-api.jar;”

NOTE: There should not be any line break while saving in text file.

And save it to a text file, say b.txt.

NOTE: semicolon(;) is used to separate two paths, and period(.) is used for setting the default directory.

classpathsetup.jpg

ii) Click on “new” button in opened Environment Variables panel and setup “CLASSPATH” variable using copied path from the text file, then click OK.

classpathnew.jpg
classpath.jpg


ii) You will see screen like this

classpath-setted.jpg

::::::::::::::::::::::::PERIOD::::::::::::::::::::::::::::

You have done it. Now next step is to test the java program and troubleshooting oracle error.

Please refer to this blog post to know how to compileĀ  and run JAVA program.

Till then watch this cool video by The Cardigans and the track is My Favourite Game:

Guess i could get that car with the chick as a hostage :)

httpv://www.youtube.com/watch?v=43qitcbdpvk


Enjoyed this post? Subscribe to Full Feeds or by Email and receive free daily updates on this Blog.

No related posts.

Related posts brought to you by Yet Another Related Posts Plugin.

  1. 4 Responses to “A concise guide to setup Oracle database connection with Java/JSP”

  2. 1

    Hi

    Thats a very cool guide / walk-through :) {I play a lotta games}

    i have the following setup:
    Oracle 9i
    Resin 3.0.17 Web server
    JDK 1.5

    i think i can edit the dbAccess.java to work on the same…
    thnx CIAO
    shabbir

    By shabbir on Tue 18th Dec, 2007

  3. 2

    Am glad you liked the walkthrough :)

    By visio159 on Wed 19th Dec, 2007

  4. 3

    Hi please if you were work on linux please let me know.
    I have Suse 10 and Oracle 10g installed and I want to do this on Suse with jakarta tomcat

    By Luis on Fri 11th Apr, 2008

  1. 1 Trackback(s)

  2. May 15, 2008: A concise guide to setup Oracle database connection with Java/JSP « A Bittersweet Life | blog

Post a Comment

November 2007
M T W T F S S
« Aug   Dec »
 1234
567891011
12131415161718
19202122232425
2627282930