I need to add a basic menu to the code so once the user logs in the get 5 choices. The code at the minute run prefectly fine with no issues but how do I break it down so its controlled by the user slecting option 1 or option 2.
I know i need to separate the code into methods but not sure how?
1 Create Table
2 Input users into new table
3 Run query1
6 query 4
7 1st prepared statement
8 2nd prepared statement
9 callable procedure.
/* JDBC default is to commit each SQL statement as it is sent to the database. Setting autocommmit=false changes the default
behaviour so that transactions have to be committed explicity.
// Creating a statement lets us issue commands against the connection.
Statement s = conn.createStatement();
// Creating and populating Actor table
s.executeUpdate("create table IF NOT EXISTS Audit( auid INT(11) PRIMARY KEY, Details CHAR(200), Recommendations CHAR(200))");
System.out.println("Created table Audit");