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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
ABC11
Helper III
Helper III

power Bi Matrix-add total in same column

Hello,

I have matrix -under column - SITEID-"ALBIAN" "HORIZON"  and LABORPAYCODE has lots. such as 801,802,814,809,826.... only 801 paycode represent for Regular time all other represent Overtime. I need have one column for regular time and one for overtime. In order to calculate overtime I need to add all paycode except 801. 

ABC11_0-1645137088466.png

 

SITEIDLaborPayCode       
ALBIANALBIANALBIANALBIANHORIZONHORIZONHORIZONHORIZONGrand Total 
801802814830801802814830  
    620  24644 
    576 14.524614.5 
702 11324    839 
288  2681526.536498.5 
11       11 
324 1     325 
505  24    529 
36   156481.5 241.5 
720 136  96.524877.5 
32452.5 842 93.5 
456 18636    678 
72       72 
80521     133 
84  696 98.524830.5 
412      16 
96481 188134 12479 
708 7936    823 
9228  8636 24266 
96858.5 48 1.5 239 
6   48  18 
    590402536691 
72241     97 
192  24162  27405 
3624  460144236702 
    76056224842 
4081.5 3921121.512567 
660  24    684 
    13376112222 
    504  24528 

Thanks,

ABC

1 ACCEPTED SOLUTION

Hi, @ABC11 

You can  add a new calculated column 'Lable Time' to replace your original field 'LaborPayCode' in your matrix visual.

Lable Time = IF('Table'[LaborPayCode]=801,"1Refgular time","2Over Time")

 

11.png

Please check my sample file for more details.

Best Regards,
Community Support Team _ Eason
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
ABC11
Helper III
Helper III

Hello Serpiva64,

Thanks for your time. This will put togather only paycode. I would like to add overtime base on laborpaycode. This is matrix table. Only 801 paycode is for Regulatime. 802,814,830 all these are represent ovetime hrs.

  SITEIDLaborPayCode       
  ALBIANALBIANALBIANALBIAN HORIZONHORIZONHORIZONHORIZON 
Employee nameEmployee NO801802814830Total801802814830Total
Tara30000     620  24644
Mita30001     576 14.524614.5
Ryan30002702 11324137     
Dinah30003288  82681526.536462.5
Kim3000411         
Reena30005324 1 1     
Nola30006505  2424     
Farah3000736    156481.5 205.5
Dylan30008720 13637  96.524120.5
Mike3000932452.5 47.5842 14
Rose30010456 18636222     
Neail3001172         
Jit3001280521 53     

 My output should be 

Employee nameEmployee NOHorizon Regular timeHorizon OvertimeHorizon Total timeAlbian RegulartimeAlbian OvertimeAlbian TotalTime  
Tara3000062024644 137137  
Mita3000157638.5614.5 88  
Ryan30002   702 702  
Dinah30003268194.5462.528129  
Kim30004   112435  
Reena30005   324 324  
Nola30006   50537542  
Farah3000715649.5205.53647.583.5  
Dylan30008 120.5120.5720222942  
Mike30009861432 32  
Rose30010   45653509  
Neail30011   72 72  
Jit30012   80 80  

Hi, @ABC11 

You can  add a new calculated column 'Lable Time' to replace your original field 'LaborPayCode' in your matrix visual.

Lable Time = IF('Table'[LaborPayCode]=801,"1Refgular time","2Over Time")

 

11.png

Please check my sample file for more details.

Best Regards,
Community Support Team _ Eason
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

serpiva64
Super User
Super User

Hi,

in your table you select column Laborpaycode and group it this way

serpiva64_0-1645138945513.png

serpiva64_1-1645139012527.png

and then in your visual you use the groupd column instead of Laborpaycode

 

If this post is useful to help you to solve your issue consider giving the post a thumbs up and accepting it as a solution !

 

 

 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.