Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Reply
marqueles
New Member

Get specific date value from Matrix Table based on a condition

Hi All,

 

How can i get de first "Payment Date" where "Balance" is negative? in this example the value will be "Viernes 07 de Enero 2022".

Some remarks:

- Amount, is a currency field and comes from the datasource

- Amount Acum, is a measure created with running total function

- Balance, is a measure created with (Initial Balance - Amount Acum)

 

Thanks in advanced

 

 

Capture.PNG

 

1 ACCEPTED SOLUTION
v-janeyg-msft
Community Support
Community Support

Hi, @marqueles 

 

You can create a measure then use it in conditional formatting. I create a simple sample.

Like this:

Measure =
VAR a =
    MINX ( FILTER ( ALL ( 'Table' ), [Balance] < 0 ), [Payment] )
RETURN
    IF ( SELECTEDVALUE ( 'Table'[Payment] ) = a, "Red" )

vjaneygmsft_0-1639475154639.png

vjaneygmsft_1-1639475165183.png

Did I answer your question ? Please mark my reply as solution. Thank you very much.
If not, please feel free to ask me.

 

Best Regards,
Community Support Team _ Janey

View solution in original post

2 REPLIES 2
v-janeyg-msft
Community Support
Community Support

Hi, @marqueles 

 

You can create a measure then use it in conditional formatting. I create a simple sample.

Like this:

Measure =
VAR a =
    MINX ( FILTER ( ALL ( 'Table' ), [Balance] < 0 ), [Payment] )
RETURN
    IF ( SELECTEDVALUE ( 'Table'[Payment] ) = a, "Red" )

vjaneygmsft_0-1639475154639.png

vjaneygmsft_1-1639475165183.png

Did I answer your question ? Please mark my reply as solution. Thank you very much.
If not, please feel free to ask me.

 

Best Regards,
Community Support Team _ Janey

lbendlin
Super User
Super User

This can be done with either measures or calculated columns. Please provide sanitized sample data that fully covers your issue. Paste the data into a table in your post or use one of the file services. 

Helpful resources

Announcements
Europe Fabric Conference

Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.

RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.