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

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Reply
SofiaVaz
Helper I
Helper I

Occupacy rate DAX Function

Hi all, 

 

please see bellow a sample of my db.

 

I'm trying to find a measure to calculate de occupation rate per vessel and voyage. It would be = On board / vessel capacity. 

 

Can you help me with a dax function to do so?

 

Thanks in advance

 

 

 

CategoriaVesselOrigemNext PortDestinoVoyVoyVesYrDateWeekWeek daysETAATAETDATDOn BoardVessel CapacityValue
PAXV1SVSASA101101San2019/02/2020817/02/2020 - 23/02/202020:30:0021:20:0011:00:0011:15:007242772
PAXV1SVSASA103103San2019/02/2020817/02/2020 - 23/02/202014:00:0013:30:0015:00:0015:08:00171427131
PAXV1SVSASN103105San2019/02/2020817/02/2020 - 23/02/202014:00:0013:30:0015:00:0015:08:0017142740
PAXV1SVSASA105107San2020/02/2020817/02/2020 - 23/02/202018:00:0017:40:0007:00:0007:10:00177427177
PAXV1SVSASA107109San2020/02/2020817/02/2020 - 23/02/202010:00:0009:35:0011:00:0011:50:00147427147
PAXV1SVSASA109111San2020/02/2020817/02/2020 - 23/02/202014:00:0013:50:0015:00:0015:15:00106427106
PAXV1SVSASA111117San2021/02/2020917/02/2020 - 23/02/202018:00:0017:35:0007:00:0008:05:00159427159
PAXV1SVSASA1176Pra2026/02/2020124/02/2020 - 01/03/202019:00:0020:23:0016:00:0016:05:00357208357
2 ACCEPTED SOLUTIONS
Tahreem24
Super User
Super User

(@SofiaVaz ,

Occupancy Rate = Sum(Table[Onboard])/Sum(Table[VesselCapacity])

Make sure both these columns are of numeric field.

 

Don't forget to give thumbs up and accept this as a solution if it helped you!!!

Please take a quick glance at newly created dashboards : Restaurant Management Dashboard , HR Analytics Report , Hotel Management Report, Sales Analysis Report , Fortune 500 Companies Analysis , Revenue Tracking Dashboard

View solution in original post

Mariusz
Community Champion
Community Champion

Hello @SofiaVaz

Try this Measurement.

Measure = 
DIVIDE(
    SUM( 'Table'[On Board] ),
    SUM( 'Table'[Vessel Capacity] )
)

Best regards
Mariusz

If this post helps,then consider accepting it as the solution.

Please feel free to connect with me.
Linkedin


View solution in original post

3 REPLIES 3
Mariusz
Community Champion
Community Champion

Hello @SofiaVaz

Try this Measurement.

Measure = 
DIVIDE(
    SUM( 'Table'[On Board] ),
    SUM( 'Table'[Vessel Capacity] )
)

Best regards
Mariusz

If this post helps,then consider accepting it as the solution.

Please feel free to connect with me.
Linkedin


amitchandak
Super User
Super User

@SofiaVaz , Try a new measure

New measure = divide(Sum('Table'[Onboard]),Sum('Table'[VesselCapacity]))

 

 

Tahreem24
Super User
Super User

(@SofiaVaz ,

Occupancy Rate = Sum(Table[Onboard])/Sum(Table[VesselCapacity])

Make sure both these columns are of numeric field.

 

Don't forget to give thumbs up and accept this as a solution if it helped you!!!

Please take a quick glance at newly created dashboards : Restaurant Management Dashboard , HR Analytics Report , Hotel Management Report, Sales Analysis Report , Fortune 500 Companies Analysis , Revenue Tracking Dashboard

Helpful resources

Announcements
Sept PBI Carousel

Power BI Monthly Update - September 2024

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

September Hackathon Carousel

Microsoft Fabric & AI Learning Hackathon

Learn from experts, get hands-on experience, and win awesome prizes.

Sept NL Carousel

Fabric Community Update - September 2024

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