public static boolean borrar(Recurso r) throws SQLException {
        try {
            ConnectionManager.executeSentence("DELETE FROM recurso WHERE id = ?", r.getID());
            if (r instanceof Libro) {
                ConnectionManager.executeSentence("DELETE FROM recurso_libro WHERE id = ?", r.getID());
            } else if (r instanceof Revista) {
                ConnectionManager.executeSentence("DELETE FROM recurso_revista WHERE id = ?", r.getID());
            } else if (r instanceof CdDvd) {
                ConnectionManager.executeSentence("DELETE FROM recurso_optico WHERE id = ?", r.getID());
            }
        } catch (Recurso.RecursoException e) {
            System.out.println("Error: " + e.getMessage());
            return false;
        }
        return true;
    }