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
RichardT_78
Helper I
Helper I

Controlling Individual matrix row data using a date column

 

How would i use the amended time stamp to influence what i saw on a row level
So, i want to only see everything after the amended date

 

RichardT_78_0-1676451250161.png

Typically for car A the counts were reduce greatly and only display the results in yellow

RichardT_78_1-1676451536591.png

Each Car would filter in the same way
Is this possible in this visual
You can use a global filter on the table, but i can’t see how to get each row to present data after a specific event
I have created a test .PBIX but i can’t see anywhere to upload or share it.

 

1 ACCEPTED SOLUTION
v-zhangti
Community Support
Community Support

Hi, @RichardT_78 

 

You can try the following methods.

vzhangti_1-1677057693204.png

Measure =
CALCULATE ( COUNT ( 'Table'[Event description] ),
    FILTER ( ALL ( 'Table' ),
        [Date] > SELECTEDVALUE ( 'Table'[Ammended time stamp] )
            && [Car] = SELECTEDVALUE ( 'Table'[Car] )
            && [Event description] = SELECTEDVALUE ( 'Table'[Event description] )
    )
)

vzhangti_0-1677057676736.png

Is this the result you expect? If not, simplify your data and give examples of your desired results.

 

Best Regards,

Community Support Team _Charlotte

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
RichardT_78
Helper I
Helper I

This is perfect and works as expected. I haven’t been using the filter function correctly. 

One bit i wasn’t clear on is that the amended date is a measure.  

This is the measure I’m using albeit i used a simple example for this question.

 

time@@ = var _cur_car_table = FILTER(ALLSELECTED('Query1') ,'Query1'[Consist]= MAX('Query1'[Consist])&& 'Query1'[EventId]=1919)

var _t2= ADDCOLUMNS(_cur_car_table,"minus" , ABS([End Date/Time]-NOW()))

var _latest =  MINX(_t2,[minus])

var _t3 = FILTER(_t2 ,[minus] = _latest)

return

DATEDIFF(MAXX(_t3,[End Date/Time]),NOW(),HOUR)

 

This searches essentially through all of the turned off events to find the last one and returns the hours since that event. 

 

I used that following measure to return the amended date , but as a measure 

Time since aux on date & time = NOW() - [time@@]/24 

 

do i create a column to use the amended date or can i use a measure in the place of 

'Table'[Ammended time stamp]

v-zhangti
Community Support
Community Support

Hi, @RichardT_78 

 

You can try the following methods.

vzhangti_1-1677057693204.png

Measure =
CALCULATE ( COUNT ( 'Table'[Event description] ),
    FILTER ( ALL ( 'Table' ),
        [Date] > SELECTEDVALUE ( 'Table'[Ammended time stamp] )
            && [Car] = SELECTEDVALUE ( 'Table'[Car] )
            && [Event description] = SELECTEDVALUE ( 'Table'[Event description] )
    )
)

vzhangti_0-1677057676736.png

Is this the result you expect? If not, simplify your data and give examples of your desired results.

 

Best Regards,

Community Support Team _Charlotte

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

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.