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
Kaustubhhh
New Member

Filtering repetetive rows in an sql database

  • Hi all, I have one dataset with column names- "tool no", "wear offset" , "tool length", "tool life" , "time stamp". In this dataset rows are coming per second.
  • There are different tool nos who have diff offsets.
  • I wanted to keep only those rows in the dataset where for a particular tool no the tool offset changes.
  • The offset change can be from 0.3 to 0.2 to again 0.3 but I want to record all these rows whenever and whereever the offset for that tool changes.
    • Kindly guide me with this.Screenshot_20231124-022155.pngScreenshot_20231124-022440.png

      Screenshot_20231124-022557.png

        

4 REPLIES 4
j_ocean
Helper V
Helper V

Group by all columns except time stamp, aggregate by min time stamp. So if you get readings like 

 

a 0.3

b 0.3

c 0.2

d 0.2

e 0.3

 

You'll retain rows a c and e, which are the time stamps when the value changed.

Anonymous
Not applicable

To ensure correct results using GroupKind.Local, you must be sure that your values are sorted--which appears to be the case.

 

--Nate

Anonymous
Not applicable

You could group on Tool and Offset, using the GroupKind.Local parameter in the Table.Group function. It'll give you a new group for each change in Offset.

 

--Nate

Hi Nate, 

Can you please elaborate about the same as I am a beginner in Power BI.

It will great if you can write down the query for this dataset

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.