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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
baribir
Helper I
Helper I

Divide every occurrence by fixed number

Hi all,

 

I have two tables in PBI.

 First,  

IDmonthActual
1000001JAN131.8759
1000001FEB201.3989
1000001MAR46.79667
1000001APR362.4535
1000001MAY981.3332
1000001JUN724.6066
1000001JUL544.9559
1000001AUG483.6966
1000001SEP566.0321
1000001OCT745.6872
1000001NOV691.189
1000001DEC720.8833
1000002JAN539.6378
1000002FEB90.21495
1000002MAR581.3458
1000002APR696.0652
1000002MAY311.4853
1000002JUN258.6118
1000002JUL859.9209
1000002AUG662.226
1000002SEP642.5379
1000002OCT683.1684
1000002NOV146.0456
1000002DEC378.2254

 

Second, 

Actual milledmonthValue
Actual Tonnes MilledJAN86160.95
Actual Tonnes MilledFEB4192.094
Actual Tonnes MilledMAR10359.42
Actual Tonnes MilledAPR85196.02
Actual Tonnes MilledMAY11880.71
Actual Tonnes MilledJUN44139.87
Actual Tonnes MilledJUL70186.39
Actual Tonnes MilledAUG79722.18
Actual Tonnes MilledSEP56502.47
Actual Tonnes MilledOCT7054.797
Actual Tonnes MilledNOV110280.9
Actual Tonnes MilledDEC70083.1

 And I want to add to the first table a column or write a DAX  to divide JAN value on the second table by JAN value of the fist table for every ID.

 

Thank you in advance.

1 ACCEPTED SOLUTION
b_saber
Regular Visitor

Step1: Go to "Manage Relationships" and add one for month. (See below)

 

image.png

 

Step2:  Add column to table1

Column = RELATED(table2[Value])

 

Step3:  Add measure to table1

Measure = CALCULATE(SUM(table1[Column])/SUM(table1[Actual]))

 

 Result:

image.png

 

 

View solution in original post

2 REPLIES 2
baribir
Helper I
Helper I

Thank you! Everything worked perfectly.

b_saber
Regular Visitor

Step1: Go to "Manage Relationships" and add one for month. (See below)

 

image.png

 

Step2:  Add column to table1

Column = RELATED(table2[Value])

 

Step3:  Add measure to table1

Measure = CALCULATE(SUM(table1[Column])/SUM(table1[Actual]))

 

 Result:

image.png

 

 

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.