/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package database.operations;

import database.connection.DatabaseConnection;
import java.io.IOException;
import java.sql.Connection;
import java.sql.PreparedStatement;
import java.sql.SQLException;

/**
 *
 * @author Ani
 */
public class DropPlayerTable {

    public static void dropPlayerTable(String tablename) throws SQLException, IOException{
        PreparedStatement pstmt =  new DatabaseConnection().getConnection().
                prepareStatement("DROP TABLE " +tablename);

         pstmt.execute();

    }

    public static void dropPlayerTable(Connection con, String tablename) throws SQLException, IOException{
        PreparedStatement pstmt =  con.prepareStatement("DROP TABLE " +tablename);

         pstmt.execute();

    }

}
