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
rpinxt
Impactful Individual
Impactful Individual

Use offset to get next line value on current line

Could anybody tell me how I would setup offset (or something better?) to get below calculated column in blue (next time)?

DateNameTimeProcessNext time
01-02-24ALHAJJX07:32:47Sumtotal07:34:54
01-02-24ALHAJJX07:34:54Apply10:32:36
01-02-24ALHAJJX10:32:36Pauze Uit10:51:13
01-02-24ALHAJJX10:51:13Pauze Uit11:24:17
01-02-24ALHAJJX11:24:17Apply12:30:54
01-02-24ALHAJJX12:30:54Pauze In13:05:07
01-02-24ALHAJJX13:05:07Pauze Uit15:01:02
01-02-24ALHAJJX15:01:02Pauze In15:19:09
01-02-24ALHAJJX15:19:09Pauze Uit15:36:23
01-02-24ALHAJJX15:36:23Apply15:57:11
01-02-24ALHAJJX15:57:11Stop0
1 ACCEPTED SOLUTION
Daniel29195
Super User
Super User

@rpinxt 

use the offset function. 

selectcolumns(

offset( 

1, 

summarize(tbl_name, tbl_name[date], tbl_name[name], tbl_name[time]) , 

orderby( tbl_name[date] , asc , tbl_name[time] , asc) , 

partitionby(tbl_name[name])

),"time", tbl_name[time])

 

NB:  change the table_bame and column base on your table name and columns name.

let me know if this helps .

 

 

If my answer helped sort things out for you, i would appreciate a thumbs up 👍 and mark it as the solution
It makes a difference and might help someone else too. Thanks for spreading the good vibes! 🤠

View solution in original post

2 REPLIES 2
rpinxt
Impactful Individual
Impactful Individual

Again thank you very much @Daniel29195 !
Was able to fit that in my data just fine.

Works like a charm 😄

Daniel29195
Super User
Super User

@rpinxt 

use the offset function. 

selectcolumns(

offset( 

1, 

summarize(tbl_name, tbl_name[date], tbl_name[name], tbl_name[time]) , 

orderby( tbl_name[date] , asc , tbl_name[time] , asc) , 

partitionby(tbl_name[name])

),"time", tbl_name[time])

 

NB:  change the table_bame and column base on your table name and columns name.

let me know if this helps .

 

 

If my answer helped sort things out for you, i would appreciate a thumbs up 👍 and mark it as the solution
It makes a difference and might help someone else too. Thanks for spreading the good vibes! 🤠

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.