The SQL standards for group by are more restrictive than the default SAP ASE standard.
The columns in a select list to be in the group by expression or to be arguments of aggregate functions.
A group by expression can contain only column names in the select list, but not those used only as arguments for vector aggregates.
set fipsflagger on
For more information about the fipsflagger option, see the set command in the Reference Manual: Commands.