Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Calculated Member

Status
Not open for further replies.

Adamba

IS-IT--Management
Aug 3, 2001
72
0
0
GB
Hi All!

Wondering if you can help me get my head round the code for a calculated member that is a percentage of a fixed level within my dimension.
What i would like to be able to do is work out the %age of the current level vs that of level 1 for it, but only if it has gone past level 1 (not the [all] level).

below is what i think the code should be and i have filled in the gaps i dont know with code ideas i have made up.

IIF(
[Products].CurrentMember.Level.Ordinal > 1
,
([products].CurrentMember,[Measures].[Value])/
([products].CurrentMember.CurrentSubCat,[Measures].[Value]),
Null
)

following is a quick layout of my cube.

Dimension: | Measure:
Products | Measures
. Sub Cat | . Measures Level
.. Supplier | Units
... Brand | Value
.... Description |

Example Dimension Products:
. Cigs
.. adam
... 1
.... box of 10 adams [smile]
.. bill
... 1
.... box of bills
. Cigar
.. adam
... 1
.... single adam
. Conf
.. bill
... 1
.... chocolate bills

Many Many Thanks in advance!
Regards,


[pc3]
Adam [glasses]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top