Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- if(cmd.getName().equalsIgnoreCase("update")) {
- if(sender instanceof ConsoleCommandSender || sender.isOp()) {
- String command = "";
- for(int i = 0; i < args.length; i++) {
- command += " " + args[i];
- }
- update(command);
- }
- }
- public void update(String update){
- Connection conn = null;
- try {
- conn = DriverManager.getConnection("jdbc:mysql://localhost:3306/bluemc_rangi", "SkyBlock", "n9pUt9zACp8SW8uO");
- } catch (SQLException e) {
- System.out.println(e.getMessage());
- }
- Result r = new Result(conn);
- try {
- r.executUpdate(update);
- r.close();
- } catch (SQLException e) {
- System.out.println(e.getMessage());
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment