Percentage Of Total

View previous topic View next topic Go down

Percentage Of Total

Post  PugMaster on Wed May 16, 2012 10:32 am




Hi

I am having problems working out percentages, as shown below. This is for call center statistics against each agent. I can work out the percentage of total numbers of incoming calls per agent that have been assigned a classification but i cannot seem to figure out how to calculate the percentage of the total number of calls for the individual classifications. for example 'Option 9' below has been selected 5 times so should be 16% of that agents calls have been given that classification.

Agent Classification Calls Classified Incomming Count Percentage Classified
Minnie Mouse All 18 30 60.00%
Minnie Mouse Option 1 2 0
Minnie Mouse Option 2 1 0
Minnie Mouse Option 3 1 0
Minnie Mouse Option 4 1 0
Minnie Mouse Option 5 3 0
Minnie Mouse Option 6 1 0
Minnie Mouse Option 7 1 0
Minnie Mouse Option 8 1 0
Minnie Mouse Option 9 5 0
Minnie Mouse Option 10 1 0
Minnie Mouse Option 11 1 0

Hopefully i have explained that well enough, i am sure i am just making a newbie mistake somewhere. I have tried doing the following.

100 * IIF(

( [Measures].[Classified],

Axis(0)(0)( Axis(0)(0).Count - 1 ).Dimension.CurrentMember.Parent

) = 0,

NULL,

[Measures].[Classified] / ( [Measures].[Classified], Axis(0)(0)( Axis(0)(0).Count - 1 ).Dimension.CurrentMember.Parent ) )

Also tried this which does give me the 60% shown above.

iif([Measures].[Classified] = 0 OR [Measures].[Call Count] = 0, NULL, [Measures].[Classified]/([Measures].[Call Count]-[Measures].[Outgoing Count]))

Kind Regards
Paul

PugMaster

Posts : 21
Join date : 2010-07-07

View user profile

Back to top Go down

Re: Percentage Of Total

Post  hang on Wed May 16, 2012 6:57 pm

I guess it's something to do with MDX keyword EXISTING. You may goole out the syntax.

hang

Posts : 528
Join date : 2010-05-07
Location : Brisbane, Australia

View user profile

Back to top Go down

Re: Percentage Of Total

Post  gsidhu on Wed May 16, 2012 7:46 pm

Try the following but change "[Classification].[Classification].CurrentMember" and "[Classification].[Classification].[(All)].[All]" depending on what your Dimension and Attribute names are:

Case When IsEmpty([Measures].[Call Count]) Then 0 Else
(
[Classification].[Classification].CurrentMember,
[Measures].[Call Count]
)/
(
[Classification].[Classification].[(All)].[All],
[Measures].[Call Count]
)
End


Then select Format String as "Percent"

technet.microsoft.com/en-us/library/ms166568.aspx

Under heading:
Defining the Percent of Total Calculations



gsidhu

Posts : 10
Join date : 2012-05-10
Location : Southern California

View user profile

Back to top Go down

Re: Percentage Of Total

Post  PugMaster on Thu May 17, 2012 2:18 am

Hi

Unfortunately that didn't work, i only get 100% or 0% not the correct values, i will look up the technet article mentioned and see what i can find.

Kind Regards
Paul

PugMaster

Posts : 21
Join date : 2010-07-07

View user profile

Back to top Go down

Re: Percentage Of Total

Post  hang on Thu May 17, 2012 3:07 am

Did EXISTING work?

hang

Posts : 528
Join date : 2010-05-07
Location : Brisbane, Australia

View user profile

Back to top Go down

Re: Percentage Of Total

Post  PugMaster on Thu May 17, 2012 7:17 am

Hi Hang

I have not worked out the syntax for that, my MDX is pretty basic :-(

Not sure i have explained it that well.

In the example I have given I need to calculate the percentage based on 5/60 but obviously in the row there is only a 0 the 60 is at the 'All' level. i have tried doing things with CurrentMember.Parent but i am not entirely sure what i am doing and it does not work, this is the most complex thing i have tried so far.

Please let me know if you need me to give a better example, i did try to upload an image of the problem but was unable to.

Kind Regards
Paul

PugMaster

Posts : 21
Join date : 2010-07-07

View user profile

Back to top Go down

Re: Percentage Of Total

Post  Sponsored content


Sponsored content


Back to top Go down

View previous topic View next topic Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum