code: public static Integer max(Connection connection, String table,
  			String column, String where, String[] args) {
  
  		Integer max = null;
  		if (count(connection, table, where, args) > 0) {
  			StringBuilder maxQuery = new StringBuilder();
  			maxQuery.append("select max(")
  					.append(CoreSQLUtils.quoteWrap(column)).append(") from ")
  					.append(CoreSQLUtils.quoteWrap(table));
  			if (where != null) {
  				maxQuery.append(" where ").append(where);
  			}
  			String sql = maxQuery.toString();
  
  			max = querySingleInteger(connection, sql, args, false);
  		}
  
  		return max;
  	}
docs: Get the max query result
  
  @param connection
  connection
  @param table
  table name
  @param column
  column name
  @param where
  where clause
  @param args
  where arguments
  @return max or null
  @since 1.1.1