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
Anonymous
Not applicable

Values Which are Preceding those to be shown in next cell using Power BI desktop

Hi , 

 

We need help in below scenario , if anyone knows the answers its really appreciated for us. 

 

Table A having below column 1st with below values.

Column 1st

1
2
3
4
5
6
7
8
9
10

 

 

Table B having below columns with values 

 

Column 1stColumn 2nd

1100
2150
5175
8200

 

Table C once left join between both abve tables 

 

Column 1stColumn 2nd
1100
2150
3 
4 
5175
6 
7 
8200
9 
10 

 

But i want output like this using Power BI desktop DAX 

 

e,g aove table if checked for 3 and 4 there is empty but i want values which preceds.

 

Column 1stColumn 2nd
1100
2150
3150
4150
5175
6175
7175
8200
9200
10200
1 ACCEPTED SOLUTION
Anonymous
Not applicable

Thanks I have found the solution , 

As fill option in transform at Power BI desktop 

View solution in original post

3 REPLIES 3
Pragati11
Super User
Super User

Hi @Anonymous ,

 

You can create a new column in your 3rd table as follows:

corrected value =
VAR PreviousRow =
CALCULATE(
MAX('Value Data'[Value]),
FILTER ( 'Value Data', 'Value Data'[Id] < EARLIER ( 'Value Data'[Id] ) )
 
)
RETURN IF('Value Data'[Value] = BLANK(), PreviousRow, 'Value Data'[Value])
 
Replace Value Data'[Id]  with Column 1st
Replace Value Data'[Value] with Column 2nd
 
The output on my test data is a s follows:
op1.png
 
If this helps and resolves the issue, appreciate a Kudos and mark it as a Solution! 🙂
 
Thanks,
Pragati

Best Regards,

Pragati Jain


MVP logo


LinkedIn | Twitter | Blog YouTube 

Did I answer your question? Mark my post as a solution! This will help others on the forum!

Appreciate your Kudos!!

Proud to be a Super User!!

Greg_Deckler
Super User
Super User

 Use Fill Down?


@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...
Anonymous
Not applicable

Thanks I have found the solution , 

As fill option in transform at Power BI desktop 

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.