cancel
Showing results for 
Search instead for 
Did you mean: 

mdx in mdxlib

08-06-2008 12:57 AM
329 views 3 comments
0 Likes
SAP Managed Tags
Subscribe

I am starting out in BPC. I have a simple function called

extic. I call this function in "formula" property of Account member "EXTICSALES".

The syntax for calling function is extic()

I dont have arguments for the function.

The formula is just an addition of 2 accounts. Since I want to standardize this function I want to have in MDXLIB.

Actual Syntax is as follows.

*Function EXTIC

[ACCOUNTDIM].[EXTICSales]=[ACCOUNTDIM].[ExtSales] + [ACCOUNTDIM].[ICSales]

*ENDFUNCTION

Error Msg below. when I process dimension.

- Formula error - syntax error - token is not valid: " [ACCOUNT].[EXTICSALES]=[ACCOUNT].[EXTSALES] + [ACCOUNT].[ICSALES]()"

Now the next question I have is in my syntax should I say Accountdim or Account.

Edited by: jack johnson on Aug 6, 2008 1:25 AM

0 Likes

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Likes

Jack,

I strongly advice you not to use these kind of formulas. This is MDX logic which will defenitley impact the performance of your application. Much better solution will be to use SQL logic. The issue is that when you are testing with only one person, the performance looks ok, but when the number of users is increasing, performance will be impacted.

I advice only to used MDX formulas for KPI/RATIOS which need recalculation on hierarchicall levels and then only when it cannot be solved directly in Excel.

Alwin

Former Member
0 Likes

HI Jack,

I guess are using BPC 5.X version, So, you need to do small modifications to formula as hirerchies play prominant roje in definig mdx formulas.

Say for example you have 3 hirerchies,then try this formula inside function

ACCOUNT.H!.[ #EXTICSales] = IIF(Account.H2.CurrentMember is Account.H2.[All Account.H2] And

Account.H3.CurrentMember is Account.H3.[All Account.H3],

(ACCOUNT.H1.ExtSales + ACCOUNTDIM.ICSales, NULL)

All hyperlinks indicate they r enclosed in square brackets

Edited by: kranthi kumar on Aug 6, 2008 11:53 AM

Former Member
0 Likes

I think I made some mistakes in repeating the same syntax we use in the dimension spreadsheets in the mdxlib.

Used functions with arguments.