Good!
I have the following code that is not returning any data to the ResultSet
defined:
Connection _con = null;
PreparedStatement _ps = null;
ResultSet _rs = null;
UsuarioBean _Ret = null;
_con = (new ConEvaluacionProveedores()).getConexion();
_ps = _con.prepareStatement("SELECT * from EPUsuario WHERE UsuCod = ? AND UsuPsw = ?");
_ps.setInt(1, pUsuario.getCedula());
_ps.setString(2, pUsuario.getContrasenia());
_rs = _ps.executeQuery();
while (_rs.next()){
_Ret = BuscarUsuario(pUsuario);
}
The DB against which I run it is Oracle , and if I execute exactly the same against Postgres it returns the data correctly.
If I make the query using java.sql.Statement
, it returns data correctly.
Is there a restriction on the use of java.sql.PreparedStatement
against Oracle or something that you may not be taking into account?
Thank you very much already.