private List<String> getSelectedVals(String tableName, List<String> cols, CachedRowSet data) throws MainException{

		try{
			//logger.info("get data for "+tableName);
			List<String> vals = new ArrayList<String>();
			for(int i = 0; i<cols.size(); i++){
				String col = cols.get(i);
				String val = data.getString(col);
				vals.add(val);
				//logger.info("Total cols="+cols.size()+"; col = "+col+ "; val ="+val);
			}
			return vals;
		}catch(SQLException ex){
			throw new MainException(ex.getMessage());
		}	

	}