Re: RANKING CUSTOMERS/CALCULATED MEASURE/SQL 2000

Tech-Archive recommends: Speed Up your PC by fixing your registry



Hi Fernando,


Here are some possible issues with your approach:

- A cube or session Named Set will not be dynamically recomputed each
time the charge type selection changes.

- Maybe you're including customers that aren't in the Top40 Named Set,
so they're all assigned a rank of 1.


This recent thread discusses a solution, though there may be performance
problems when the row set is large:

http://groups.google.com/group/microsoft.public.sqlserver.olap/browse_fr
m/thread/51673105feb39eaf/4b8c06c0fc689ac9#4b8c06c0fc689ac9
>>
Newsgroups: microsoft.public.sqlserver.olap
From: "alanr"
Date: 13 Oct 2005 09:06:25 -0700

Subject: visual rank calculated member on server is very very slow

Greetings!

I am struggling with the performance of a visual ranking calculation
defined on the server. I based this on posts from Tom Chester and
others. I am using the September CTP (which as a side note seems to
have eliminated the need to do order the set before ranking?). Excel
2003 pivot table is client. Note that the member won't work with OWC
because the axis doesn't have the measure on it.

For very small dimensions it is just fine but for those with even a few
hundred members it takes more than a minute. With a thousand members
takes 10+ minutes. Ugh:( This is probably because it is performing
the rank calculation for each cell and nothing is cached between cells.

I have seen some very interesting posts from Deepak that suggest how to
cache ordered sets using "WITH" and Generate but I don't think there is
a way to do that within a server calculated member? Also, I don't want
to cache the ordered set, I want to cache the RANK with it's elegant
handling of ties.

Here is the definition of the member

CREATE MEMBER CURRENTCUBE.[MEASURES].[Rank Desc]
AS
-- IF GRAND TOTAL THEN NULL
IIF(StrToSet("Axis(1)").Item(0).Item(0).Dimension.CurrentMember.Level
IS StrToSet("Axis(1)").Item(0).Item(0).Dimension.DefaultMember.Level,
NULL,
-- MEASURE IS LAST ITEM ON COLUMN AXIS - IF EMPTY THEN NULL
IIF(IsEmpty(StrToSet("Axis(0)").Item(0).Item(StrToSet("Axis(0)").Item(0)
Co­unt
-1)), NULL,
-- DIMENSION IS LAST ITEM ON ROW AXIS
Rank(StrToSet("Axis(1)").Item(0).Item(StrToSet("Axis(1)").Item(0).Count
-1).Dimension.CurrentMember,
StrToSet("Axis(1)").Item(0).Item(StrToSet("Axis(1)").Item(0).Count
-1).Dimension.CurrentMember.Siblings,
-- RANK DESC
-1 * StrToSet("Axis(0)").Item(0).Item(StrToSet("Axis(0)").Item(0).Count
-1)))),
VISIBLE = 1
...
>>


- Deepak

Deepak Puri
Microsoft MVP - SQL Server

*** Sent via Developersdex http://www.developersdex.com ***
.



Relevant Pages

  • Re: Do I need to open port 137 and 138 from members server to the trusted PDC emulator ?
    ... I am using a Windows 2003 server member of a PDC NT4 domain. ... The PDC NT4 domain is trusted with an Active ... I understand that these ports needs to be opened ...
    (microsoft.public.windows.server.active_directory)
  • Re: Do I need to open port 137 and 138 from members server to the trusted PDC emulator ?
    ... The PDC NT4 domain is trusted with an Active Directory domain. ... I want to list my AD domain users from my Windows 2003 server member of my NT4 domain. ... I understand that these ports needs to be opened between PDC and DC but not between MEMBER servers and the PDC Emulator of the trusted domain. ...
    (microsoft.public.windows.server.active_directory)
  • Re: Do I need to open port 137 and 138 from members server to the trusted PDC emulator ?
    ... I am using a Windows 2003 server member of a PDC NT4 domain. ... The PDC NT4 domain is trusted with an Active ...
    (microsoft.public.windows.server.active_directory)
  • Re: KRB Error
    ... There is so much that can be done with a security template that wouldn't be obvious from any common interface that the best bet would be to identify what changes were made. ... > party vendor was used to harden security on this server and another ... > both members of Domain A. Another member server on Domain A did not> have ... >>> Member servers on Domain A cannot access resources on Domain B. ...
    (microsoft.public.win2000.active_directory)
  • Re: Do I need to open port 137 and 138 from members server to the trusted PDC emulator ?
    ... The PDC NT4 domain is trusted with an Active Directory domain. ... I want to list my AD domain users from my Windows 2003 server member of my NT4 domain. ... I understand that these ports needs to be opened between PDC and DC but not between MEMBER servers and the PDC Emulator of the trusted domain. ...
    (microsoft.public.windows.server.active_directory)