import java.sql.*; public class DataBase { public static void main(String args[]) { DataBase db = new DataBase("SuppDB"); ResultSet rs = db.execute("select * from S"); try { while (rs.next()) // 6th line of JDBC System.out.println(rs.getString("S_NO")); // 7th line of JDBC } catch (SQLException e) { System.out.println(e.getMessage()); } } // NOT COMPLETE, see lecture notes page 76 public DataBase(String name) { // NOT COMPLETE, see lecture notes page 77 } public ResultSet execute(String query) { ResultSet rs = null; // NOT COMPLETE, see lecture notes page 78, for the first 5 lines of JDBC // 1: // 2: // 3: // 4: // 5: return rs; } }