Error: Value is either too Large or too Small for a decimal

HHoensheid
New Contributor II

Hello, 

I am receiving an error "Value is either too large or too small for a decimal" in a Cube View when I try to divide values in two rows using the cube view math.

 

When exported into Excel the math for the same division yields 8.2, which does not seem like it would be too large or too small for a decimal. 

Example: 

GetDataCell(A#NetInc / A#Diluted_Shares_Outstanding_AsAdjusted_DC)  

HHoensheid_0-1642696444290.png  

I am trying to divide the two rows shown above. 

HHoensheid_1-1642696565678.png

Using the Excel divide function produces a clean 8.26, which I would not expect to be "too large or too small for a decimal"

The second member is a Dynamic Calc member that dynamically changes the view to either YTD or QTD depending on user's POV, but is not doing any math on the account value itself. 

Any help or insight into this issue would be appreciated. Thank you!

1 ACCEPTED SOLUTION

NicolasArgente
Valued Contributor

Hi there,

Please in your getdatacell can you try with that ; GetDataCell(Divide(S#Scenario1,S#Scenario2)):Name(Ratio)
Say thanks by pressy Kuddos below.
Nic 

Connect with me on:
LinkedIn: https://www.linkedin.com/in/nicolas-argente/
Website: https://aiqos.io
If you want to lift yourself up, lift up someone else.

View solution in original post

3 REPLIES 3

NicolasArgente
Valued Contributor

Hi there,

Please in your getdatacell can you try with that ; GetDataCell(Divide(S#Scenario1,S#Scenario2)):Name(Ratio)
Say thanks by pressy Kuddos below.
Nic 

Connect with me on:
LinkedIn: https://www.linkedin.com/in/nicolas-argente/
Website: https://aiqos.io
If you want to lift yourself up, lift up someone else.

HHoensheid
New Contributor II

Hi Nic, 

Thank you, this solution worked. I am still unclear as to why the Divide function works sometimes as opposed to using the "/" operator. the "/" operator has worked before for me, but not in all cases. Seems to be some inconsistency there. I will use the Divide function as a default. 
Thanks again!

NicolasArgente
Valued Contributor

Good! You are right to use Divide by default as it also reduce the risk of dividing by zero. OS does the magic on the backend 😊

Connect with me on:
LinkedIn: https://www.linkedin.com/in/nicolas-argente/
Website: https://aiqos.io
If you want to lift yourself up, lift up someone else.