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

Join the FabCon + SQLCon recap series. Up next: Power BI, Real-Time Intelligence, IQ and AI, and Data Factory take center stage. All sessions are available on-demand after the live show. Register now

Reply
Anonymous
Not applicable

Staff Utilisation

Hi,

 

I'm trying to do something which I thought would be really simple but obviously not for me so here I am.  I have a table similar to the one below.  I am trying to work out staff %age utilisation for each employee for each period.  Transaction Type 100 is utilised, all other Transaction Codes are not utilised.

 

Any help greatly appreciated.

 

Employee No.Transation Type CodeUnitsPeriod
1000100156.021
10001031.861
100030050.871
10001001.252
200042530.001
2000100240.001
2000100177.502
20003006.502
20004008.002
3000100103.501
30003005.001
30004008.751
1 ACCEPTED SOLUTION
az38
Community Champion
Community Champion

Hi @Anonymous 

try new table

Staff Utilisation = SUMMARIZE('Table1';Table1[Employee No.];Table1[Period];"%utilization";divide(calculate(SUM(Table1[Units]);'Table1'[Transation Type Code]=100);calculate(SUM(Table1[Units]));0))

do not hesitate to give a kudo to useful posts and mark solutions as solution


do not hesitate to give a kudo to useful posts and mark solutions as solution
LinkedIn

View solution in original post

4 REPLIES 4
az38
Community Champion
Community Champion

Hi @Anonymous 

try new table

Staff Utilisation = SUMMARIZE('Table1';Table1[Employee No.];Table1[Period];"%utilization";divide(calculate(SUM(Table1[Units]);'Table1'[Transation Type Code]=100);calculate(SUM(Table1[Units]));0))

do not hesitate to give a kudo to useful posts and mark solutions as solution


do not hesitate to give a kudo to useful posts and mark solutions as solution
LinkedIn
Anonymous
Not applicable

Hi Az38,

 

I'm getting an error DAX comparison operations do not support comparing values of type Text with values of type Interger.  Consider using the VALUE or FORMAT function to convert one of the values.

 

I've looked at my data and only the units are Number the rest are text ?

 

Thanks

az38
Community Champion
Community Champion

Hi @Anonymous 

in power query mode set all digit columns as Number types

go to the Query Editor, set mouse on column and in Transform ribbon choose Data Type Whole Number or Decimal Number (for Units column)

maybe.. you will need to replace "." to "," in Units column (it depends on your localization)

do not hesitate to give a kudo to useful posts and mark solutions as solution


do not hesitate to give a kudo to useful posts and mark solutions as solution
LinkedIn
Anonymous
Not applicable

Hi az38,

 

Legend !! I found it, it was treating the Transaction Type code as a number.  I put "" around the 100 code and worked perfectly.

 

Thanks for your help !

Helpful resources

Announcements
April Power BI Update Carousel

Power BI Monthly Update - April 2026

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

New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

FabCon and SQLCon Highlights Carousel

FabCon &SQLCon Highlights

Experience the highlights from FabCon & SQLCon, available live and on-demand starting April 14th.