Updated on 2023-12-22 GMT+08:00

GAUSS-00241 -- GAUSS-00250

GAUSS-00241: "aggregates not allowed in JOIN conditions"

SQLSTATE: 42803

Description: The JOIN condition uses the aggregate function.

Solution: Do not use the aggregate function in the JOIN condition.

GAUSS-00242: "aggregates not allowed in GROUP BY clause"

SQLSTATE: 42803

Description: The GROUP BY clause uses the aggregate function.

Solution: Do not use the aggregate function in the GROUP BY clause.

GAUSS-00243: "aggregate functions not allowed in a recursive query's recursive term"

SQLSTATE: 42P19

Description: The recursive query uses the aggregate function.

Solution: Do not use the aggregate function in the recursive query.

GAUSS-00244: "window functions not allowed in WHERE clause"

SQLSTATE: 42P20

Description: The WHERE clause uses the window function.

Solution: Do not use the window function in the WHERE clause.

GAUSS-00245: "window functions not allowed in JOIN conditions"

SQLSTATE: 42P20

Description: The JOIN condition uses the window function.

Solution: Do not use the window function in the JOIN condition.

GAUSS-00246: "window functions not allowed in HAVING clause"

SQLSTATE: 42P20

Description: The syntax is not supported.

Solution: Modify the SQL statement.

GAUSS-00247: "window functions not allowed in GROUP BY clause"

SQLSTATE: 42P20

Description: The GROUP BY clause uses the window function.

Solution: Do not use the window function in the GROUP BY clause.

GAUSS-00248: "window functions not allowed in window definition"

SQLSTATE: 42P20

Description: The partition or ORDER BY clause uses the window function.

Solution: Do not use the window function in the partition or ORDER BY clause.

GAUSS-00249: "column '%s.%s' must appear in the GROUP BY clause or be used in an aggregate function"

SQLSTATE: 42803

Description: group by uses the aggregate function, or variables in the target list do not exist in variables for group by.

Solution: Do not use the aggregate function in group by, or ensure that variables in the target list exist in variables for group by.

GAUSS-00250: "subquery uses ungrouped column '%s.%s' from outer query"

SQLSTATE: 42803

Description: The subquery uses an external ungrouped column.

Solution: Ensure that the subquery uses an external grouped column.