@Override
	public Set<Account> getAccounts(User owner) {

		Set<Account> accounts = new HashSet<Account>();
		PreparedStatement pStmt = null;
		ResultSet rs = null;
		
		try {
			
			pStmt = conn.prepareStatement("SELECT * FROM ACCOUNT WHERE user_login = ? ORDER BY id;");
			pStmt.setString(1, owner.getLogin());
			rs = pStmt.executeQuery();
			
			while (rs.next()) {
				
				Account account = new Account();
				account.setUser(owner);
				account.setId(rs.getInt("id"));
				account.setFunds(rs.getDouble("funds"));
				accounts.add(account);
				
			}
			
		} catch (SQLException e) {

			e.printStackTrace();
			
		} finally {
			
			closeResource(pStmt);
			closeResource(rs);
			
		}
		
		return accounts;
		
	}