Thin Oracle Driver
0 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Abhi_Raje
Posted On:   Wednesday, April 3, 2002 09:23 PM

I Have Done following programme and complie it,it doesnot given any error? but while runtime it gives an error End of TNS Data channel Pleae Help me? import java.sql.*; class JdbcTest { public static void main (String args []) throws SQLException { // Load Oracle driver DriverManager.registerDriver (new oracle.jdbc.driver.OracleDriver()); // Connect to the local database Connection conn = DriverManager.getConnection ("jdbc:oracle:thin:@192.168.100.2:1521:orcl", "sco", "tiger"); // Query the employee names Statement stmt = conn.createStatement (); ResultSet rset = stmt.executeQuery ("select schsm0302 fro   More>>

I Have Done following programme and complie it,it doesnot
given any error? but while runtime it gives an error
End of TNS Data channel
Pleae Help me?
import java.sql.*;
class JdbcTest {
public static void main (String args []) throws SQLException {
// Load Oracle driver
DriverManager.registerDriver (new oracle.jdbc.driver.OracleDriver());

// Connect to the local database
Connection conn =
DriverManager.getConnection ("jdbc:oracle:thin:@192.168.100.2:1521:orcl",
"sco", "tiger");

// Query the employee names
Statement stmt = conn.createStatement ();
ResultSet rset = stmt.executeQuery ("select schsm0302 from schsm03");

// Print the name out
while (rset.next ())
System.out.println (rset.getString (1));
}
}

   <<Less
About | Sitemap | Contact