Pessoal,
Estou usando o modelo DAO, e criei uma estrutura para conter vários métodos como lista todos, excluir, atualizar para uma classe
de agendamento. O Código abaixo implementa uma pesquisa, o nome do arquivo desse trecho de código é AgendamentoDAOImpl
public Agendamento pesquisar(String data) throws AgendamentoDAOException {
PreparedStatement smt = null;
ResultSet rs = null;
String html = "";
html += "<html>";
html += "<body>";
try{
smt = conn.prepareStatement("select * from agendamento where data like ?");
rs = smt.executeQuery();
while (rs.next()){
html += "Proprietario:" + rs.getString("propveiculo") + "<br/>";
html += "Data:" + rs.getString("data") + "<br/>";
}
rs.close();
smt.close();
}
catch( SQLException err ){
throw new AgendamentoDAOException( err );
}
finally {
ConnectionAgendamentoFactory.close( conn, smt, rs);
}
// TODO Auto-generated method stub
return null;
}
E já fiz algo semelhante para listar todos os agendamentos usando um jsp, e isso funcionou.

Agora com relação ao código acima, quando coloco a variavel data vem a mensagem
org.apache.jasper.JasperException: Unable to compile class for JSP:
An error occurred at line: 25 in the jsp file: /pesquisaAG.jsp data cannot be resolved
Mesmo tentando colocar a váriavel data entre aspas duplas vem a mensagem de erro:
An error occurred at line: 25 in the jsp file: /pesquisaAG.jsp
Type mismatch: cannot convert from Agendamento to List
O que eu pretendo fazer é uma busca através da Data e apresentar os dados,
Como fazer que o valor data seja reconhecido ?
Att,
Rodrigo Faria