public void getValues(String cate, boolean pop, boolean rat, double lngMax, double lngMin, double latMax, double latMin, ArrayList<Business> biz) throws SQLException{
		String category = cate;
		/*
		double lngMax = -75.197005;
		double lngMin = -75.200994;
		double latMax = 39.956863;
		double latMin = 39.954336;
		*/
		boolean rating = rat;
		boolean popularity = pop;
		String createView = "create VIEW current_view as "
				+ "select business.business_id, name, full_address, photo_url, stars, review_count, longitude, latitude "
				+ "from business, businesscategory "
				+ "where business.business_id = businesscategory.business_id "
				+ "AND businesscategory.category = \"" + category + "\" "
				+ "AND longitude <= " + lngMax + " "
				+ "AND longitude >= " + lngMin + " "
				+ "AND latitude <= " + latMax + " "
				+ "AND latitude >= " + latMin + " ";
		String prefixQuery = "SELECT * from current_view WHERE ";
		String starQuery = "stars >= (SELECT Max(stars) as maxrating "
												  + "FROM current_view) - 0.5 ";
		String and = "AND ";
		String reviewCountQuery = "review_count >= (SELECT Max(review_count) as maxPopularity "
														+ " FROM current_view) - 0.2*(SELECT Max(review_count) as maxPopularity FROM current_view)";
		
		String dropView = "DROP VIEW current_view";
		
		stmt.execute(dropView);
		
		Business b;
		String n, f;
		int r;
		double s, lo, la;
		
		try {
			ResultSet rsx = getResult(createView);
			if (rating && popularity){
				prefixQuery += starQuery + and + reviewCountQuery;
				rsx = getResult(prefixQuery);
			}
			else if (rating && !popularity){
				prefixQuery += starQuery;
				rsx = getResult(prefixQuery);
			}
			else if (popularity && !rating){
				prefixQuery += reviewCountQuery;
				rsx = getResult(prefixQuery);
			}
			else{
				rsx = getResult("SELECT * from current_view");
			}
			
			while (rsx.next()) {
				n = rsx.getString("name");
				f = rsx.getString("full_address");
				r = rsx.getInt("review_count");
				s = rsx.getDouble("stars");
				lo = rsx.getDouble("longitude");
				la = rsx.getDouble("latitude");
				b = new Business(n, f, r, s, lo, la);

				biz.add(b);
			}
	
		}

		catch (Exception e) {
			System.out.println("Caught an error");
		}
		
		
	}