I am new in java Jdbc I am going to write simple jdbc program `
import java.sql.*;
class jdbcDemo
{
public static void main(String[] args) throws Exception
{
Class.forName("oracle.jdbc.OracleDriver");
Connection con=DriverManager.getConnection("jdbc:oracle:thin:@localhost:1521:xe","Scott","tiger");
Statement st=con.createStatement();
ResultSet rs=st.executeQuery("select * from rk");
while(rs.next())
{
System.out.println(rs.getInt(1)+"---"+rs.getString(2)+"---"+rs.getInt(3));
}
con.close();
}
}
after Successful compiling program At runtime i found following error
I had used editplus editor and also i had created rk table in oracle 12c database
need help to fix issue