Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
Anonymous
Not applicable

Calculation Not Working for Calculated Column

Hi Ya'll,

 

I have these 2 formulas:

 

Measure
LTIP Shares = ROUNDDOWN(CALCULATE(SUM(LTIP[Amount]))/'Stock Price'[Stock Price Value],0)
Sample: 25,000 / 54.78 = 456 shares (the round down eliminates the excess because it won't yield a full share)
 

Calculated Column

PSU = Switch(
True(),
LTIP[Management Level] IN {"5B","5A","4B","4A","3"},ROUNDDOWN([LTIP Shares]*.25,0),
LTIP[Management Level] IN {"2","1","0"},ROUNDDOWN([LTIP Shares]*.50,0),
Blank()
)
 
What I want is if a worker is in a specific management level, I want it to spit out 25% or 50% of the LTIP shares for that worker and round down so it give me the full shares. So say the worker is a 5B and they are entitled to 456 shares, they should get 25% of those shares as PSUs and should give me a value of 114 -- it's instead giving me 178! 
 
What am I doing wrong? Been wracking my brain and I feel like I am overlooking something...
 
Any help would be great please! Thanks!
1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@Anonymous ,

You can nor measure in a column.

 

Try a measure like this


PSU =
sumx(Values(LTIP[Management Level]) ,
Switch(
True(),
max(LTIP[Management Level]) IN {"5B","5A","4B","4A","3"},ROUNDDOWN([LTIP Shares]*.25,0),
max(LTIP[Management Level]) IN {"2","1","0"},ROUNDDOWN([LTIP Shares]*.50,0),
Blank()
))

View solution in original post

2 REPLIES 2
amitchandak
Super User
Super User

@Anonymous ,

You can nor measure in a column.

 

Try a measure like this


PSU =
sumx(Values(LTIP[Management Level]) ,
Switch(
True(),
max(LTIP[Management Level]) IN {"5B","5A","4B","4A","3"},ROUNDDOWN([LTIP Shares]*.25,0),
max(LTIP[Management Level]) IN {"2","1","0"},ROUNDDOWN([LTIP Shares]*.50,0),
Blank()
))

Anonymous
Not applicable

Doh! You're right! 

Thanks so much! I appreciate your help here!

Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

LearnSurvey

Fabric certifications survey

Certification feedback opportunity for the community.