Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: SQL-92 syntax question?
> Is the following syntax valid in SQL-92 (Oracle allows it):
>
> SELECT a, exprFunc1(b), exprFunc2(c)
> FROM ...
> GROUP BY a, exprFunc1(b);
>
> exprFunc1() is say, a DayOfWeek() method returning the day of week of a
> given date.
No, its not a valid SQL 92 statement, since that standard specifies a query-specification as:
SELECT [ALL | DISTINCT] select-list
FROM table-reference [,table-reference]...
[WHERE search-condition] [GROUP BY column-name [, column-name]...] [HAVING search-condition]
As you can see above, you can only list column names in the GROUP BY clause.
Regards,
Jarl
-- Jarl Hermansson http://www.mimer.com Product Development Sysdeco Mimer ABReceived on Mon Jan 26 1998 - 00:00:00 CST