import java.sql.*;
class ConnectionDB{
public static void main(String args[])throws Exception{
Class.forName("oracle.jdbc.driver.OracleDriver");
System.out.println("Driver Loaded");
Connection con=DriverManager.getConnection("jdbc:oracle:thin:@localhost:1521:XE","system","suman");
System.out.println("Connected");
con.close();
}
}
No comments:
Post a Comment