private String userType(String username) {
		String type = null;
		ResultSet rs;

		try {

			PreparedStatement statement = connection
					.prepareStatement("SELECT * FROM Users "
							+ "WHERE username = ?");

			statement.setString(1, username);

			rs = statement.executeQuery();

			while (rs.next()) {
				type = rs.getString("type");
				break;
			}

			rs.close();

		} catch (SQLException e) {
			e.printStackTrace();
		}

		return type;
	}