Welcome to the Java Programming Forums


The professional, friendly Java community. 21,500 members and growing!


The Java Programming Forums are a community of Java programmers from all around the World. Our members have a wide range of skills and they all have one thing in common: A passion to learn and code Java. We invite beginner Java programmers right through to Java professionals to post here and share your knowledge. Become a part of the community, help others, expand your knowledge of Java and enjoy talking with like minded people. Registration is quick and best of all free. We look forward to meeting you.


>> REGISTER NOW TO START POSTING


Members have full access to the forums. Advertisements are removed for registered users.

Results 1 to 3 of 3

Thread: connect to oracle Server via Jdbc

  1. #1
    Junior Member
    Join Date
    Aug 2013
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default connect to oracle Server via Jdbc

    hello
    im trying to connect oracle server in another Computer but i get Exception
    here is my code :
    public PersonDa()
    {
    try {
    Class.forName("oracle.jdbc.driver.DriverManager");
    connection = DriverManager.getConnection("oracle.jdbc:thin:192. 168.32.1:1521rcl", "SYSTEM", "123456");
    } catch (Exception e)
    {
    e.printStackTrace();
    }
    }


  2. #2
    Administrator copeg's Avatar
    Join Date
    Oct 2009
    Location
    US
    Posts
    5,320
    Thanks
    181
    Thanked 833 Times in 772 Posts
    Blog Entries
    5

    Default Re: connect to oracle Server via Jdbc

    but i get Exception
    Care to share what that may be, lest you wish us to guess?

  3. #3
    Member
    Join Date
    Jul 2013
    Posts
    219
    Thanks
    0
    Thanked 18 Times in 17 Posts

    Default Re: connect to oracle Server via Jdbc

    Hello.
    Try to get one simple working oracle JDBC program by visiting some online JDBC tutorials.
    And compare that code with what you have written. Of course, compare just the core logic - obtaining connection, executing statement, etc.
    You should be able to find out the errors.

    Syed.

Similar Threads

  1. How to Connect to an Excel Spreadsheet using JDBC in Java
    By JavaPF in forum JDBC and Database Tutorials
    Replies: 14
    Last Post: August 27th, 2013, 11:57 AM
  2. Connect to MySQL database on remote IP/port through JDBC
    By javauser in forum JDBC & Databases
    Replies: 6
    Last Post: September 7th, 2012, 02:11 AM
  3. Java server Faces and Oracle
    By rcbandit in forum JDBC & Databases
    Replies: 0
    Last Post: December 8th, 2011, 02:59 PM
  4. How to Connect to an Excel Spreadsheet using JDBC in Java
    By JavaPF in forum Java Code Snippets and Tutorials
    Replies: 7
    Last Post: June 21st, 2011, 02:12 AM
  5. JDBC Oracle 10g - problems to connect
    By nestorkorni in forum JDBC & Databases
    Replies: 0
    Last Post: March 10th, 2011, 12:48 PM