The Frog wrote on 30.10.2009 11:07:
select
product.manufacturer,
product.brand,
SUM(sales.qtysold * sales.unitprice) as turnover,
(select count(*) from cube_sales.sales as Q WHERE SUM(sales.qtysold *
sales.unitprice) > turnover) + 1 as rank
from
cube_sales.
On Fri, Oct 30, 2009 at 10:42 AM, Raymond O'Donnell wrote:
> On 30/10/2009 10:07, The Frog wrote:
>> select
>> product.manufacturer,
>> product.brand,
>> SUM(sales.qtysold * sales.unitprice) as turnover,
>> (select count(*) from cube_sales.sales as Q WHERE SUM(sales.qtysold
On 30/10/2009 10:07, The Frog wrote:
> select
> product.manufacturer,
> product.brand,
> SUM(sales.qtysold * sales.unitprice) as turnover,
> (select count(*) from cube_sales.sales as Q WHERE SUM(sales.qtysold *
> sales.unitprice) > turnover) + 1 as rank
You can't use the al
Hi Everyone,
I am having an issue with a query that I thought would be a fairly
simple matter to implement, but apparently I have done something
wrong. Can anyone point me in the right direction for a solution and
explain where I have made my mistake? The idea is to produce a rank
value for each r