Archives of the TeradataForum
Message Posted: Tue, 08 Jan 2002 @ 15:19:57 GMT
Looks strange, but this should work...(note, no aggregate functions used with OLAP functions. If you need to aggregate, it can be done with a derived table.)
Select Prod , Area , Volume Sold , Rank(Volume Sold) From FactTable Group By 1,2 Qualify Rank(Volume Sold) <= 3 Order By 1,2,3
Let me know.
|Copyright 2016 - All Rights Reserved|
|Last Modified: 27 Dec 2016|