protected void close(ResultSet rs, Statement ps, Connection conn)
    {
        if (rs != null)
        {
            try
            {
                rs.close();
            }
            catch(SQLException e)
            {
                System.out.println("The result set cannot be closed." + e);
            }
        }
        if (ps != null)
        {
            try
            {
                ps.close();
            }
            catch (SQLException e)
            {
                System.out.println("The result set cannot be closed." + e);
            }
        }
        if (conn != null)
        {
            try
            {
                conn.close();
            }
            catch (SQLException e)
            {
                System.out.println("The result set cannot be closed." + e);
            }
        }
    }