dbTalk Databases Forums  

Create a measure of a dimension by level

microsoft.public.sqlserver.olap microsoft.public.sqlserver.olap


Discuss Create a measure of a dimension by level in the microsoft.public.sqlserver.olap forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Botinha
 
Posts: n/a

Default Create a measure of a dimension by level - 01-14-2004 , 05:38 AM






Hello!!

Here is what i have:
Dimension:
Name:[Organização Concurso]
Level: [UNR],[RD],[SR]

Measure formula for rank:
Rank([Organização Concurso].currentmember,order({[Organização
Concurso].[Intermediario].members},([Measures].[Pontos do
Concurso]),BDESC),[Measures].[Pontos do Concurso])
But this measure ranks the dimension with all the members of the
dimension.
What i want is:
[UNR] [RD] [SR] [Pontos do Concurso]
A A1 A1.1 40
A A2 A2.1 30
B B1 B1.1 20
B B1 B1.2 10
result of raking:
[UNR] [RD] [SR] [Pontos do Concurso] [Rank]
A A2 A2.1 30 1
A A1 A1.1 40 2
B B1 B1.2 10 1
B B1 B1.1 20 2

How should i do this?
It is possible?

Thanks

André Fonseca

Reply With Quote
  #2  
Old   
Tom Chester
 
Posts: n/a

Default Re: Create a measure of a dimension by level - 01-14-2004 , 09:33 AM






Instead of this:
{[Organização Concurso].[Intermediario].members}

Try this:
{[Organização Concurso].CurrentMember.Parent.Children

public @ the domain below
www.tomchester.net

"Botinha" <botinha (AT) netcabo (DOT) pt> wrote

Quote:
Hello!!

Here is what i have:
Dimension:
Name:[Organização Concurso]
Level: [UNR],[RD],[SR]

Measure formula for rank:
Rank([Organização Concurso].currentmember,order({[Organização
Concurso].[Intermediario].members},([Measures].[Pontos do
Concurso]),BDESC),[Measures].[Pontos do Concurso])
But this measure ranks the dimension with all the members of the
dimension.
What i want is:
[UNR] [RD] [SR] [Pontos do Concurso]
A A1 A1.1 40
A A2 A2.1 30
B B1 B1.1 20
B B1 B1.2 10
result of raking:
[UNR] [RD] [SR] [Pontos do Concurso] [Rank]
A A2 A2.1 30 1
A A1 A1.1 40 2
B B1 B1.2 10 1
B B1 B1.1 20 2

How should i do this?
It is possible?

Thanks

André Fonseca



Reply With Quote
  #3  
Old   
Botinha
 
Posts: n/a

Default Re: Create a measure of a dimension by level - 01-15-2004 , 06:09 AM



Thanks!I really nead that....
It works fine!!

But it returns an "#err" in totals and when the dimension is on the
filter area. How should i avoid this?

Thanks in advanced...

Have a good day!

André Fonseca

"Tom Chester" <publicNOSPAM (AT) tomchester (DOT) net> wrote

Quote:
Instead of this:
{[Organização Concurso].[Intermediario].members}

Try this:
{[Organização Concurso].CurrentMember.Parent.Children

public @ the domain below
www.tomchester.net

"Botinha" <botinha (AT) netcabo (DOT) pt> wrote in message
news:9587965.0401140338.7c6fac5a (AT) posting (DOT) google.com...
Hello!!

Here is what i have:
Dimension:
Name:[Organização Concurso]
Level: [UNR],[RD],[SR]

Measure formula for rank:
Rank([Organização Concurso].currentmember,order({[Organização
Concurso].[Intermediario].members},([Measures].[Pontos do
Concurso]),BDESC),[Measures].[Pontos do Concurso])
But this measure ranks the dimension with all the members of the
dimension.
What i want is:
[UNR] [RD] [SR] [Pontos do Concurso]
A A1 A1.1 40
A A2 A2.1 30
B B1 B1.1 20
B B1 B1.2 10
result of raking:
[UNR] [RD] [SR] [Pontos do Concurso] [Rank]
A A2 A2.1 30 1
A A1 A1.1 40 2
B B1 B1.2 10 1
B B1 B1.1 20 2

How should i do this?
It is possible?

Thanks

André Fonseca

Reply With Quote
  #4  
Old   
Tom Chester
 
Posts: n/a

Default Re: Create a measure of a dimension by level - 01-15-2004 , 11:16 AM



I thought that might be next Try this:

IIF( {[Organização Concurso].CurrentMember IS
{[Organização Concurso].DefaultMember,
NULL,
<formula goes here> )

public @ the domain below
www.tomchester.net

"Botinha" <botinha (AT) netcabo (DOT) pt> wrote

Quote:
Thanks!I really nead that....
It works fine!!

But it returns an "#err" in totals and when the dimension is on the
filter area. How should i avoid this?

Thanks in advanced...

Have a good day!

André Fonseca

"Tom Chester" <publicNOSPAM (AT) tomchester (DOT) net> wrote

Instead of this:
{[Organização Concurso].[Intermediario].members}

Try this:
{[Organização Concurso].CurrentMember.Parent.Children

public @ the domain below
www.tomchester.net

"Botinha" <botinha (AT) netcabo (DOT) pt> wrote in message
news:9587965.0401140338.7c6fac5a (AT) posting (DOT) google.com...
Hello!!

Here is what i have:
Dimension:
Name:[Organização Concurso]
Level: [UNR],[RD],[SR]

Measure formula for rank:
Rank([Organização Concurso].currentmember,order({[Organização
Concurso].[Intermediario].members},([Measures].[Pontos do
Concurso]),BDESC),[Measures].[Pontos do Concurso])
But this measure ranks the dimension with all the members of the
dimension.
What i want is:
[UNR] [RD] [SR] [Pontos do Concurso]
A A1 A1.1 40
A A2 A2.1 30
B B1 B1.1 20
B B1 B1.2 10
result of raking:
[UNR] [RD] [SR] [Pontos do Concurso] [Rank]
A A2 A2.1 30 1
A A1 A1.1 40 2
B B1 B1.2 10 1
B B1 B1.1 20 2

How should i do this?
It is possible?

Thanks

André Fonseca



Reply With Quote
  #5  
Old   
Botinha
 
Posts: n/a

Default Re: Create a measure of a dimension by level - 01-21-2004 , 08:24 AM



Thanks again!!

Sorry to make this kind of questions but i'm new in this business!!!

André Fonseca

"Tom Chester" <publicNOSPAM (AT) tomchester (DOT) net> wrote

Quote:
I thought that might be next Try this:

IIF( {[Organização Concurso].CurrentMember IS
{[Organização Concurso].DefaultMember,
NULL,
formula goes here> )

public @ the domain below
www.tomchester.net

"Botinha" <botinha (AT) netcabo (DOT) pt> wrote in message
news:9587965.0401150409.4421889d (AT) posting (DOT) google.com...
Thanks!I really nead that....
It works fine!!

But it returns an "#err" in totals and when the dimension is on the
filter area. How should i avoid this?

Thanks in advanced...

Have a good day!

André Fonseca

"Tom Chester" <publicNOSPAM (AT) tomchester (DOT) net> wrote in message
news:<1jdNb.361$4h7.8509 (AT) news (DOT) uswest.net>...
Instead of this:
{[Organização Concurso].[Intermediario].members}

Try this:
{[Organização Concurso].CurrentMember.Parent.Children

public @ the domain below
www.tomchester.net

"Botinha" <botinha (AT) netcabo (DOT) pt> wrote in message
news:9587965.0401140338.7c6fac5a (AT) posting (DOT) google.com...
Hello!!

Here is what i have:
Dimension:
Name:[Organização Concurso]
Level: [UNR],[RD],[SR]

Measure formula for rank:
Rank([Organização Concurso].currentmember,order({[Organização
Concurso].[Intermediario].members},([Measures].[Pontos do
Concurso]),BDESC),[Measures].[Pontos do Concurso])
But this measure ranks the dimension with all the members of the
dimension.
What i want is:
[UNR] [RD] [SR] [Pontos do Concurso]
A A1 A1.1 40
A A2 A2.1 30
B B1 B1.1 20
B B1 B1.2 10
result of raking:
[UNR] [RD] [SR] [Pontos do Concurso] [Rank]
A A2 A2.1 30 1
A A1 A1.1 40 2
B B1 B1.2 10 1
B B1 B1.1 20 2

How should i do this?
It is possible?

Thanks

André Fonseca

Reply With Quote
  #6  
Old   
Tom Chester
 
Posts: n/a

Default Re: Create a measure of a dimension by level - 01-21-2004 , 10:09 AM



No prob André.

public @ the domain below
www.tomchester.net

"Botinha" <botinha (AT) netcabo (DOT) pt> wrote

Quote:
Thanks again!!

Sorry to make this kind of questions but i'm new in this business!!!

André Fonseca

"Tom Chester" <publicNOSPAM (AT) tomchester (DOT) net> wrote

I thought that might be next Try this:

IIF( {[Organização Concurso].CurrentMember IS
{[Organização Concurso].DefaultMember,
NULL,
formula goes here> )

public @ the domain below
www.tomchester.net

"Botinha" <botinha (AT) netcabo (DOT) pt> wrote in message
news:9587965.0401150409.4421889d (AT) posting (DOT) google.com...
Thanks!I really nead that....
It works fine!!

But it returns an "#err" in totals and when the dimension is on the
filter area. How should i avoid this?

Thanks in advanced...

Have a good day!

André Fonseca

"Tom Chester" <publicNOSPAM (AT) tomchester (DOT) net> wrote in message
news:<1jdNb.361$4h7.8509 (AT) news (DOT) uswest.net>...
Instead of this:
{[Organização Concurso].[Intermediario].members}

Try this:
{[Organização Concurso].CurrentMember.Parent.Children

public @ the domain below
www.tomchester.net

"Botinha" <botinha (AT) netcabo (DOT) pt> wrote in message
news:9587965.0401140338.7c6fac5a (AT) posting (DOT) google.com...
Hello!!

Here is what i have:
Dimension:
Name:[Organização Concurso]
Level: [UNR],[RD],[SR]

Measure formula for rank:
Rank([Organização Concurso].currentmember,order({[Organização
Concurso].[Intermediario].members},([Measures].[Pontos do
Concurso]),BDESC),[Measures].[Pontos do Concurso])
But this measure ranks the dimension with all the members of the
dimension.
What i want is:
[UNR] [RD] [SR] [Pontos do Concurso]
A A1 A1.1 40
A A2 A2.1 30
B B1 B1.1 20
B B1 B1.2 10
result of raking:
[UNR] [RD] [SR] [Pontos do Concurso] [Rank]
A A2 A2.1 30 1
A A1 A1.1 40 2
B B1 B1.2 10 1
B B1 B1.1 20 2

How should i do this?
It is possible?

Thanks

André Fonseca



Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.