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
mmk_PB
Regular Visitor

Calculating Revenue/Time with Revenue table and Time table

Hi folks,

 

I have recently encountered an issue when calculating profitability in Power BI desktop.

 

Below are the two tables to start with. Note that a Client ID may:

1. Only exist in the Rev Table

2. Only exist in the Time Table

3. Exists in both tables

 

Rev Table

Client IDRevenue
150
220
220
350
450

 

Time Table

Client IDTime
10.5
21
31
31
50.5

 

I would like to achieve below:

Revenue/Time Table

Client IDRevenueTime
1500.5
2401
3502
4500
500.5

 

I created a unique list of Client ID by appending the two tables as New (and removed duplicated Client ID and removed errors). However, I was unable to create an "One-to-many" relationship between the new table and the table or the Time table.

 

I am relatively new to Power BI so I might not be using the easiest approach. Any suggestion/help is greatly appreciated!

 

1 ACCEPTED SOLUTION
AlexisOlson
Super User
Super User

I'd suggest doing the Append Queries as New and then grouping by Client ID rather than removing duplicates.

 

AlexisOlson_0-1635363379054.png

 

View solution in original post

4 REPLIES 4
AlexisOlson
Super User
Super User

I'd suggest doing the Append Queries as New and then grouping by Client ID rather than removing duplicates.

 

AlexisOlson_0-1635363379054.png

 

Thanks! I was looking for a clean solution like this!

Fowmy
Super User
Super User

@mmk_PB 

I was able do the same steps as you have done,

Fowmy_0-1635363057289.png

File attached below

 

Did I answer your question? Mark my post as a solution! and hit thumbs up


Subscribe and learn Power BI from these videos

Website LinkedIn PBI User Group

Hello @mmk_PB ,

 

If  you just want to create the Revenue/Time table from two tables you provided. You can use merge ables as new and based on client id column.

 

Then the result will be as you provided.

 

If this solved the issue, please accept 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.