Home / Documentation / FAQ / Support / Download Limitations and Workarounds

### Limitations and Workarounds Index

> 1. The SQL SELECT statement

1. The SQL SELECT statement

> Referencing aliased expressions in the where clause - Currently the engine can not resolve aliased expressions in the `WHERE` clause of a `SELECT` statement. For example,

>     SELECT "number" * 20 AS "number_mul_20"
>       FROM MyTable
>      WHERE "number_mul_20" > 200

> To work around this problem move the expression that is aliased directly in to the where clause. A working example is therefore;

>     SELECT "number" * 20 AS "number_mul_20"
>       FROM MyTable
>      WHERE "number" * 20 > 200

> Using aggregate functions in the having clause - A related limitation is that the `HAVING` clause can not resolve aggregate functions directly. The following example demonstrates this problem,

>       SELECT "age"
>         FROM People
>     GROUP BY "age"
>       HAVING count(*) >= 1

> To work around this problem you must define a column which is aliased to the aggregate function. A working example is;

>       SELECT "age", count(*) AS "age_count"
>         FROM People
>     GROUP BY "age"
>       HAVING "age_count" >= 1

Last Updated: Sun Mar 25 02:32:49 EST 2001 Mckoi SQL Database Copyright © 2000, 2001 Diehl and Associates, Inc. All rights reserved.