Last active
November 30, 2020 18:53
-
-
Save charles-silva/6d38b6f17b7c3c86bdc426a259054a9f to your computer and use it in GitHub Desktop.
[Consulta java]#java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Override | |
public List<Usuar> findAll() { | |
StringBuilder sql = new StringBuilder(); | |
sql.append(" SELECT Isn,Nome_Login,Nome_Completo,Bloqueado,Administrador,Cod_Funcionario,Senha_Hash,Senha1 FROM USUAR"); | |
try { | |
List<Usuar> usuars = db.query(sql.toString(), new UsuarRowMapper()); | |
return !usuars.isEmpty() ? usuars : null; | |
} catch (EmptyResultDataAccessException e) { | |
return null; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment