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
kevin_tran22
Frequent Visitor

Merging Data Rows in PowerBI

I have a table that looks like this: 

kevin_tran22_0-1685556945218.png

This data comes from a CSV report that I've pulled from online and connected it to my online data source that is already in PowerBI. This data source is connected by the ID column. I want to merge these two rows to reduce the # of rows we have in my data table report. Highlighted in yellow are the data points that I want to keep. What is the best way to merge both rows and have the PowerBI report look cleaner? 

 

3 REPLIES 3
vanessafvg
Super User
Super User

can you provide the data in text format?  

also what type of scenarios  are you expecting?  is there a rule of what to select over the other?

 

 





If I took the time to answer your question and I came up with a solution, please mark my post as a solution and /or give kudos freely for the effort 🙂 Thank you!

Proud to be a Super User!




@vanessafvg I want first line of data to be deleted only if there is a time series correction (there are some lines that are not time series and less commonly multiple time series). Essentially I want my PBI data table to be less clustered. I'm hoping that I can eliminate one of these lines of data somehow. Yes the rule should be to take data from the bottom row excepted for the effective start date, we want the min value of that. 

 

ID  Type    Name          Attribute Name   Action                  Effective Start Date   Effective End Date   New Value       Old Value  Knowledge Date   Modified By
1 Equity Common Units Payment Rank Time Series Correction 1/1/2000 12/22/2020 Not Applicable 12/23/2020 TS:mgeick
1 Equity Common Units Payment Rank 12/23/2020 12/23/2020 First lien 12/23/2020 mgeick

 

This is an example of one way of doing it. 

 

I created 2 additional tables in power query that grouped the by the id and min date, and then the id and max date, and i used these two tables by merging with them to bring back the rows i was interested in, assuming this scenario always works.  Obviously if you can push this logic back if your data is really big to a system that has good compute, but if you working with small amounts of data and you dont have access to a database, this should work ok.

 

see attached

 





If I took the time to answer your question and I came up with a solution, please mark my post as a solution and /or give kudos freely for the effort 🙂 Thank you!

Proud to be a Super User!




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.