Re: Is relational theory irrelevant?
Date: 12 Nov 2003 14:00:42 -0800
Message-ID: <db76e830.0311121400.7a548bb9_at_posting.google.com>
Christopher Browne <cbbrowne_at_acm.org> wrote in message news:<borj63$1i4fo4$1_at_ID-125932.news.uni-berlin.de>...
select employeeId , employeeName, SalaryAmt,DepartmentId
, rank() over (partition by departmentId order by salaryAmt) as
SalaryRank
The windowing functions are support by Oracle and DB2 but not by
Microsoft SQL Server.
Received on Wed Nov 12 2003 - 23:00:42 CET
> A long time ago, in a galaxy far, far away, Lauri Pietarinen <lauri.pietarinen_at_atbusiness.com> wrote:
> > OK, but is
> >
> > select top 5 * from (
> > select * from emp order by sal
> > )
> >
> > legal SQL now a'days?
> >
> > Is it supported in products?
>
> No, it is not 'legal SQL.'
>
> It is a proprietary extension used by one vendor.
The SQL standard now includes the concept of windowing functions in
addition to the grouping functions. The SQL statement to Rank by
salary within each department would be on the order of:
from employees