Hi,

I'm having a terrible (but simple) problem... I'm trying to make 2 database connections: first I make one, use it and close it, then I make the other , use it and close it. Here's the code (very simple code) :

import java.sql.*;

public class Teste {

public static void main( String[] args ) throws Exception {

Class.forName("oracle.jdbc.driver.OracleDriver");

Connection con = DriverManager.getConnection("jdbc:oracle:thin:@192 .168.0.4:1521:orcl","myUser","myPassword");
Statement stmt = con.createStatement();
ResultSet rs = stmt.executeQuery("select * from client");
while (rs.next()) {
System.out.println(rs.getString("name"));
}
rs.close();
stmt.close();
con.close();

System.out.println();
System.out.println();

Connection con2 = DriverManager.getConnection("jdbc:oracle:thin:@192 .168.0.4:1521:orcl","myUser","myPassword");
Statement stmt2 = con2.createStatement();
ResultSet rs2 = stmt2.executeQuery("select * from news");
System.out.println();
while (rs2.next()) {
System.out.println(rs2.getString("title") );
}

rs2.close();
stmt2.close();
con2.close();

}

}

It's a very simple code... The problem is that when I'm running this code over JDK 1.4.1_01 (build 1.4.1_01-b01, mixed mode) over Red Hat Linux 7.2 the jvm stops (stop the processing in the prompt) when getting the second connection (in the line: Connection con2 = ...). The java process simply stops, but it doesn't finish (it don't come back to the linux prompt).
In the same jvm version running over windows xp all works fine.

Does anyone know what's hapenning ?

Thanks in advance,

Sergio Stateri Jr
sergio.jr@tesla.com.br