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
gmiro
Regular Visitor

Connecting time slots with time stamp data

Hi!
I'm new to the forum, and I'd like to get any help regarding this issue. I have two datasets connected by time. One of them is a time slot with a status for each of them:

 

Category
EventInitial timeEnd timeDuration
ConditionA11/11/2020 00:00:0011/11/2020 01:49:2101:49:21
ConditionB11/11/2020 01:49:2111/11/2020 01:51:2900:02:08
ConditionA11/11/2020 01:51:2911/11/2020 02:14:4100:23:12
ConditionB11/11/2020 02:14:4111/11/2020 02:14:5600:00:15

 

The second table is a timestamp typical table for time-based data:

DateData AData B
11/11/2020 0:00:002535
11/11/2020 0:10:004520
11/11/2020 0:20:002025
11/11/2020 0:30:003230
11/11/2020 0:40:001245
11/11/2020 0:50:0045210
11/11/2020 1:00:0050220
11/11/2020 1:10:00241235

 

How I can connect each row of the second table with the appropriate data from the 1st table?

Any help would be appreciated. Thanks!

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@gmiro , You can get data from first table into second table like

 

maxx(filter(first, second[Date]>= first[Initial time] && second[Date]<= first[End time]), first[Duration])

 

also refer the way to get data from one table to another - https://www.youtube.com/watch?v=czNHt7UXIe8

 

 

View solution in original post

1 REPLY 1
amitchandak
Super User
Super User

@gmiro , You can get data from first table into second table like

 

maxx(filter(first, second[Date]>= first[Initial time] && second[Date]<= first[End time]), first[Duration])

 

also refer the way to get data from one table to another - https://www.youtube.com/watch?v=czNHt7UXIe8

 

 

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.