| Oracle FAQ | Your Portal to the Oracle Knowledge Grid | |
Home -> Community -> Usenet -> comp.databases.theory -> Re: Celko: help with an experiment
>> One question I still have on this issue is when the aggregate
does not
refer to any columns of the table, as in
select max(12) as Twelve from T;
for different cardinalities of T. My best try at the SQL-92 standard
suggests
this should return as many rows as there are rows in T. I don't have
a copy
of the 99 standard to try to decipher its verdict. <<
I would say that we build a table of (n) rows with the expression 12 in all of them, then group on the phantom column and return one row with 12 in it. If I just wrote:
select 12 as Twelve from T;
then i woudl get (n) rows each with 12 in them. Received on Tue Jul 09 2002 - 12:25:56 CDT
![]() |
![]() |